This is an automated email from the ASF dual-hosted git repository.
madhan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ranger.git
The following commit(s) were added to refs/heads/master by this push:
new e686c2426 RANGER-3923: updated sample_gds_client.py to use multiple
users, groups and zones - #2
e686c2426 is described below
commit e686c24266b2e05e461211f20dc43308cf78006c
Author: Madhan Neethiraj <[email protected]>
AuthorDate: Tue Feb 20 10:29:23 2024 -0800
RANGER-3923: updated sample_gds_client.py to use multiple users, groups and
zones - #2
---
.../src/main/python/sample_gds_client.py | 34 +++++++++++++++++-----
1 file changed, 26 insertions(+), 8 deletions(-)
diff --git a/ranger-examples/sample-client/src/main/python/sample_gds_client.py
b/ranger-examples/sample-client/src/main/python/sample_gds_client.py
index 7ec711e65..eab3f3087 100644
--- a/ranger-examples/sample-client/src/main/python/sample_gds_client.py
+++ b/ranger-examples/sample-client/src/main/python/sample_gds_client.py
@@ -360,19 +360,17 @@ policy = gds.add_project_policy(project_2.id,
RangerPolicy({ 'name': project_2.n
print(f' added policy for project {project_2.name}: {policy}')
-exit(0)
-
print(f'Removing dataset_in_project: id={d1_in_p1.id}')
gds.remove_dataset_in_project(d1_in_p1.id)
print(f' deleted dataset_in_project: id={d1_in_p1.id}')
-print(f'Removing dataset_in_project: id={d1_in_p2.id}')
-gds.remove_dataset_in_project(d1_in_p2.id)
-print(f' deleted dataset_in_project: id={d1_in_p2.id}')
+print(f'Removing dataset_in_project: id={d2_in_p1.id}')
+gds.remove_dataset_in_project(d2_in_p1.id)
+print(f' deleted dataset_in_project: id={d2_in_p1.id}')
-print(f'Removing dataset_in_project: id={d2_in_p2.id}')
-gds.remove_dataset_in_project(d2_in_p2.id)
-print(f' deleted dataset_in_project: id={d2_in_p2.id}')
+print(f'Removing dataset_in_project: id={d3_in_p2.id}')
+gds.remove_dataset_in_project(d3_in_p2.id)
+print(f' deleted dataset_in_project: id={d3_in_p2.id}')
print(f'Removing data_share_in_dataset: id={dshid_1.id}')
gds.remove_data_share_in_dataset(dshid_1.id)
@@ -382,6 +380,26 @@ print(f'Removing data_share_in_dataset: id={dshid_2.id}')
gds.remove_data_share_in_dataset(dshid_2.id)
print(f' deleted data_share_in_dataset: id={dshid_2.id}')
+print(f'Removing data_share_in_dataset: id={dshid_3.id}')
+gds.remove_data_share_in_dataset(dshid_3.id)
+print(f' deleted data_share_in_dataset: id={dshid_3.id}')
+
+print(f'Removing data_share_in_dataset: id={dshid_4.id}')
+gds.remove_data_share_in_dataset(dshid_4.id)
+print(f' deleted data_share_in_dataset: id={dshid_4.id}')
+
+print(f'Removing data_share_in_dataset: id={dshid_5.id}')
+gds.remove_data_share_in_dataset(dshid_5.id)
+print(f' deleted data_share_in_dataset: id={dshid_5.id}')
+
+print(f'Removing data_share_in_dataset: id={dshid_6.id}')
+gds.remove_data_share_in_dataset(dshid_6.id)
+print(f' deleted data_share_in_dataset: id={dshid_6.id}')
+
+print(f'Removing data_share_in_dataset: id={dshid_7.id}')
+gds.remove_data_share_in_dataset(dshid_7.id)
+print(f' deleted data_share_in_dataset: id={dshid_7.id}')
+
print(f'Removing shared_resource: id={hive_resource_1.id}')
gds.remove_shared_resource(hive_resource_1.id)
print(f' removed shared_resource: id={hive_resource_1.id}')