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

(Updated 八月 9, 2017, 5:33 a.m.)


Review request for ranger, Alok Lal, Ankita Sinha, Don Bosco Durai, Colm O 
hEigeartaigh, Gautam Borad, Madhan Neethiraj, Ramesh Mani, Selvamohan 
Neethiraj, Velmurugan Periasamy, and Qiang Zhang.


Changes
-------

add two changes, one is to remove the try/catch statement in 
"getSupportedServiceDef" , the other is to move the "supportedServiceDefs" 
definition down from the static variable declarations down to the instance 
variable declarations.


Bugs: RANGER-1725
    https://issues.apache.org/jira/browse/RANGER-1725


Repository: ranger


Description
-------

It is incorrect to judge whether you need to create a RangerServiceDef object 
for a given service.
The current judgment condition is in the 
org.apache.ranger.plugin.store.EmbeddedServiceDefsUtil#getOrCreateServiceDef, 
as follows
boolean createServiceDef = (CollectionUtils.isEmpty(supportedServiceDefs) || 
supportedServiceDefs.contains(serviceDefName));
It means When the supportedServiceDefs is empty, the RangerServiceDef object 
for the specified service will be created, but I think this judge is incorrect.


Diffs (updated)
-----

  
agents-common/src/main/java/org/apache/ranger/plugin/store/EmbeddedServiceDefsUtil.java
 0bc09f6 


Diff: https://reviews.apache.org/r/61452/diff/2/

Changes: https://reviews.apache.org/r/61452/diff/1-2/


Testing
-------


Thanks,

pengjianhua

Reply via email to