[
https://issues.apache.org/jira/browse/RANGER-4182?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Madhan Neethiraj updated RANGER-4182:
-------------------------------------
Fix Version/s: 2.5.0
> Ranger Admin - Enable isRecursive option to additional default policies while
> service creation
> ----------------------------------------------------------------------------------------------
>
> Key: RANGER-4182
> URL: https://issues.apache.org/jira/browse/RANGER-4182
> Project: Ranger
> Issue Type: Improvement
> Components: Ranger
> Reporter: Kishor Gollapalliwar
> Assignee: Kishor Gollapalliwar
> Priority: Major
> Fix For: 3.0.0, 2.5.0
>
>
> Currently while service creation when we create additional default policies
> via curl we do not have option to support isRecursive. This is mostly due to
> [https://github.com/apache/ranger/blob/2d9af00153e8326c7b5eb80e7c86e1e8988dfbdc/agents-common/src/main/java/org/apache/ranger/plugin/service/RangerBaseService.java#L209,]
> where we are setting it explicitly false. We need a mechanism where in user
> should be able to dynamically enable/ disable is-isRecursive option for a
> resource using JSON provided.
>
> Sample curl command to create service & additional default policies
> {code:java}
> curl -u admin:<ADMIN_PASSWORD> -ivk -H "Accept:application/json" -H
> "Content-Type:application/json" -X POST
> 'http://localhost:6080/service/plugins/services' -d @hive_test.json {code}
> {code:java}
> vim hive_test.json
> { "isEnabled": "true", "type": "hive", "configs": { "username":
> "hive", "password": "hive", "cluster.name": "My Dummy Cluster",
> "jdbc.driverClassName": "org.apache.hive.jdbc.HiveDriver", "jdbc.url":
> "none", "enable.hive.metastore.lookup": "true",
> "hive.site.file.path": "/etc/hive/conf/hive-site.xml",
> "policy.download.auth.users": "hive,hdfs,impala",
> "tag.download.auth.users": "hive,hdfs,impala",
> "policy.grantrevoke.auth.users": "hive,impala",
> "setup.additional.default.policies": "true", "default-policy.1.name":
> "User URL Policy", "default-policy.1.resource.url": "/test/kishor",
> "default-policy.1.policyItem.1.users": "kishor",
> "default-policy.1.policyItem.1.accessTypes": "read,write",
> "default-policy.1.resource-flag.is-recursive": "true",
> "default.policy.users": "impala,hive,hue,beacon,admin,dpprofiler" },
> "name": "hive_test", "displayName": "Hive service", "description": "Hive
> repository/ service for Kishor" }
> {code}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)