> On July 22, 2020, 9:12 a.m., Pradeep Agrawal wrote:
> > security-admin/src/main/java/org/apache/ranger/rest/ServiceREST.java
> > Lines 2325 (patched)
> > <https://reviews.apache.org/r/72696/diff/1/?file=2236087#file2236087line2325>
> >
> >     @Dinesh:
> >     
> >     After understanding the problem now and comments from Abhay and Madhan. 
> > I have attached a patch in the Jira please try that and optimize if 
> > possible. 
> >     
> >     Also test below use cases:
> >     
> >     1) what if a single policy json has mapping like this:
> >     service1(source) is mapped to service2(target)
> >     service2(source) is mapped to service1(target)
> >     
> >     2) what if policy json is updated first with target service name by 
> > someone manually and then imported.

Thanks Pradeep, There is already code at #2344 svcStore.createPolicyMap(), 
which is changing the policy service name and zone name to targeted service 
name and zone name.


- Dineshkumar


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/72696/#review221309
-----------------------------------------------------------


On July 22, 2020, 1:14 p.m., Dineshkumar Yadav wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/72696/
> -----------------------------------------------------------
> 
> (Updated July 22, 2020, 1:14 p.m.)
> 
> 
> Review request for ranger, Ankita Sinha, Gautam Borad, Kishor Gollapalliwar, 
> Abhay Kulkarni, Madhan Neethiraj, Mehul Parikh, Pradeep Agrawal, and 
> Velmurugan Periasamy.
> 
> 
> Repository: ranger
> 
> 
> Description
> -------
> 
> source policy is getting deleted while importing policy with deleteifexists 
> parameter
> 
> 
> Diffs
> -----
> 
>   security-admin/src/main/java/org/apache/ranger/rest/ServiceREST.java 
> 18abc2958 
> 
> 
> Diff: https://reviews.apache.org/r/72696/diff/2/
> 
> 
> Testing
> -------
> 
> Steps to Reproduce: 
> 1. Create 2 Hbase service i.e. hbase1 and hbase2, 
> 2. Create some policies in service - hbase1
> 3. perform policy import from source service - hbase1 to target service - 
> hbase2
> 4. Policies from service - hbase1 gets successfully imported to service - 
> hbase2 as per deleteifexist parameter feature
> 5. After import, Policies from source service - hbase1 also gets deleted
> 
> After patch source service is not getting deleted.
> 
> testing is in progress.
> 
> 
> Thanks,
> 
> Dineshkumar Yadav
> 
>

Reply via email to