You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ranger.apache.org by Abhay Kulkarni <ak...@hortonworks.com> on 2016/11/19 06:17:13 UTC

Review Request 53924: Unit test failure in TestDefaultPolicyResourceMatcher (Java 8)

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

Review request for ranger and Madhan Neethiraj.


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


Repository: ranger


Description
-------

Updated PolicyResource Matching algorithm to handle service-definitions which support multiple valid resource hierarchies.


Diffs
-----

  agents-common/src/main/java/org/apache/ranger/plugin/policyresourcematcher/RangerDefaultPolicyResourceMatcher.java 5e2fa74 
  agents-common/src/test/resources/resourcematcher/test_defaultpolicyresourcematcher.json 71995dc 

Diff: https://reviews.apache.org/r/53924/diff/


Testing
-------

Compiled and ran unit tests with both JDK 1.7 and JDK 1.8


Thanks,

Abhay Kulkarni


Re: Review Request 53924: Unit test failure in TestDefaultPolicyResourceMatcher (Java 8)

Posted by Madhan Neethiraj <ma...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/53924/#review156520
-----------------------------------------------------------


Ship it!




Ship It!

- Madhan Neethiraj


On Nov. 21, 2016, 8:05 p.m., Abhay Kulkarni wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53924/
> -----------------------------------------------------------
> 
> (Updated Nov. 21, 2016, 8:05 p.m.)
> 
> 
> Review request for ranger and Madhan Neethiraj.
> 
> 
> Bugs: RANGER-1222
>     https://issues.apache.org/jira/browse/RANGER-1222
> 
> 
> Repository: ranger
> 
> 
> Description
> -------
> 
> Updated PolicyResource Matching algorithm to handle service-definitions which support multiple valid resource hierarchies.
> 
> 
> Diffs
> -----
> 
>   agents-common/src/main/java/org/apache/ranger/plugin/policyresourcematcher/RangerDefaultPolicyResourceMatcher.java 5e2fa74 
>   agents-common/src/test/resources/resourcematcher/test_defaultpolicyresourcematcher.json 71995dc 
> 
> Diff: https://reviews.apache.org/r/53924/diff/
> 
> 
> Testing
> -------
> 
> Compiled and ran unit tests with both JDK 1.7 and JDK 1.8
> 
> 
> Thanks,
> 
> Abhay Kulkarni
> 
>


Re: Review Request 53924: Unit test failure in TestDefaultPolicyResourceMatcher (Java 8)

Posted by Abhay Kulkarni <ak...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/53924/
-----------------------------------------------------------

(Updated Nov. 21, 2016, 8:05 p.m.)


Review request for ranger and Madhan Neethiraj.


Changes
-------

Addressed review comment.


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


Repository: ranger


Description
-------

Updated PolicyResource Matching algorithm to handle service-definitions which support multiple valid resource hierarchies.


Diffs (updated)
-----

  agents-common/src/main/java/org/apache/ranger/plugin/policyresourcematcher/RangerDefaultPolicyResourceMatcher.java 5e2fa74 
  agents-common/src/test/resources/resourcematcher/test_defaultpolicyresourcematcher.json 71995dc 

Diff: https://reviews.apache.org/r/53924/diff/


Testing
-------

Compiled and ran unit tests with both JDK 1.7 and JDK 1.8


Thanks,

Abhay Kulkarni


Re: Review Request 53924: Unit test failure in TestDefaultPolicyResourceMatcher (Java 8)

Posted by Nigel Jones <jo...@uk.ibm.com>.

> On Nov. 21, 2016, 3:07 p.m., Nigel Jones wrote:
> > Ship It!

I can confirm this patch resolves the Java 8 compile problems. The unit test succeeds though I've not yet tried ranger in anger following this patch


- Nigel


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


On Nov. 19, 2016, 6:17 a.m., Abhay Kulkarni wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53924/
> -----------------------------------------------------------
> 
> (Updated Nov. 19, 2016, 6:17 a.m.)
> 
> 
> Review request for ranger and Madhan Neethiraj.
> 
> 
> Bugs: RANGER-1222
>     https://issues.apache.org/jira/browse/RANGER-1222
> 
> 
> Repository: ranger
> 
> 
> Description
> -------
> 
> Updated PolicyResource Matching algorithm to handle service-definitions which support multiple valid resource hierarchies.
> 
> 
> Diffs
> -----
> 
>   agents-common/src/main/java/org/apache/ranger/plugin/policyresourcematcher/RangerDefaultPolicyResourceMatcher.java 5e2fa74 
>   agents-common/src/test/resources/resourcematcher/test_defaultpolicyresourcematcher.json 71995dc 
> 
> Diff: https://reviews.apache.org/r/53924/diff/
> 
> 
> Testing
> -------
> 
> Compiled and ran unit tests with both JDK 1.7 and JDK 1.8
> 
> 
> Thanks,
> 
> Abhay Kulkarni
> 
>


Re: Review Request 53924: Unit test failure in TestDefaultPolicyResourceMatcher (Java 8)

Posted by Nigel Jones <jo...@uk.ibm.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/53924/#review156459
-----------------------------------------------------------


Ship it!




Ship It!

- Nigel Jones


On Nov. 19, 2016, 6:17 a.m., Abhay Kulkarni wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53924/
> -----------------------------------------------------------
> 
> (Updated Nov. 19, 2016, 6:17 a.m.)
> 
> 
> Review request for ranger and Madhan Neethiraj.
> 
> 
> Bugs: RANGER-1222
>     https://issues.apache.org/jira/browse/RANGER-1222
> 
> 
> Repository: ranger
> 
> 
> Description
> -------
> 
> Updated PolicyResource Matching algorithm to handle service-definitions which support multiple valid resource hierarchies.
> 
> 
> Diffs
> -----
> 
>   agents-common/src/main/java/org/apache/ranger/plugin/policyresourcematcher/RangerDefaultPolicyResourceMatcher.java 5e2fa74 
>   agents-common/src/test/resources/resourcematcher/test_defaultpolicyresourcematcher.json 71995dc 
> 
> Diff: https://reviews.apache.org/r/53924/diff/
> 
> 
> Testing
> -------
> 
> Compiled and ran unit tests with both JDK 1.7 and JDK 1.8
> 
> 
> Thanks,
> 
> Abhay Kulkarni
> 
>


Re: Review Request 53924: Unit test failure in TestDefaultPolicyResourceMatcher (Java 8)

Posted by Madhan Neethiraj <ma...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/53924/#review156464
-----------------------------------------------------------


Fix it, then Ship it!





agents-common/src/main/java/org/apache/ranger/plugin/policyresourcematcher/RangerDefaultPolicyResourceMatcher.java (line 487)
<https://reviews.apache.org/r/53924/#comment226650>

    It might be efficient to first check if firstValidResourceDefHierarchy matches the resource, before checking for all possible hierarchies. Please review.


- Madhan Neethiraj


On Nov. 19, 2016, 6:17 a.m., Abhay Kulkarni wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/53924/
> -----------------------------------------------------------
> 
> (Updated Nov. 19, 2016, 6:17 a.m.)
> 
> 
> Review request for ranger and Madhan Neethiraj.
> 
> 
> Bugs: RANGER-1222
>     https://issues.apache.org/jira/browse/RANGER-1222
> 
> 
> Repository: ranger
> 
> 
> Description
> -------
> 
> Updated PolicyResource Matching algorithm to handle service-definitions which support multiple valid resource hierarchies.
> 
> 
> Diffs
> -----
> 
>   agents-common/src/main/java/org/apache/ranger/plugin/policyresourcematcher/RangerDefaultPolicyResourceMatcher.java 5e2fa74 
>   agents-common/src/test/resources/resourcematcher/test_defaultpolicyresourcematcher.json 71995dc 
> 
> Diff: https://reviews.apache.org/r/53924/diff/
> 
> 
> Testing
> -------
> 
> Compiled and ran unit tests with both JDK 1.7 and JDK 1.8
> 
> 
> Thanks,
> 
> Abhay Kulkarni
> 
>