You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ranger.apache.org by Ankita Sinha <an...@freestoneinfotech.com> on 2022/02/15 12:57:09 UTC

Review Request 73848: RANGER-3621 Optimise Tag iterator

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

Review request for ranger, Madhan Neethiraj and Subhrat Chaudhary.


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


Repository: ranger


Description
-------

Optimise the logic of Tag iterator

Problem Statement:
Tags in the iterator are not freed till the whole processing of all Tags are done. So, in the case where there are lot of tag, the performance can be impacted as the large number of tags are held by iterator for long time. This causes performance degradation while retrieving the tags from db.

Solution:
The individual tag as soon as it is processed should be removed from the iterator.


Diffs
-----

  security-admin/src/main/java/org/apache/ranger/biz/RangerTagDBRetriever.java 1b7e8b272 


Diff: https://reviews.apache.org/r/73848/diff/1/


Testing
-------

Tested Manually by using bulk tags.


Thanks,

Ankita Sinha


Re: Review Request 73848: RANGER-3621 Optimise Tag iterator

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


Fix it, then Ship it!





security-admin/src/main/java/org/apache/ranger/biz/RangerTagDBRetriever.java
Lines 272 (patched)
<https://reviews.apache.org/r/73848/#comment313028>

    Please consider similar optimization when building a service-policies cache, if applicable.


- Abhay Kulkarni


On Feb. 15, 2022, 12:57 p.m., Ankita Sinha wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/73848/
> -----------------------------------------------------------
> 
> (Updated Feb. 15, 2022, 12:57 p.m.)
> 
> 
> Review request for ranger, Madhan Neethiraj and Subhrat Chaudhary.
> 
> 
> Bugs: RANGER-3621
>     https://issues.apache.org/jira/browse/RANGER-3621
> 
> 
> Repository: ranger
> 
> 
> Description
> -------
> 
> Optimise the logic of Tag iterator
> 
> Problem Statement:
> Tags in the iterator are not freed till the whole processing of all Tags are done. So, in the case where there are lot of tag, the performance can be impacted as the large number of tags are held by iterator for long time. This causes performance degradation while retrieving the tags from db.
> 
> Solution:
> The individual tag as soon as it is processed should be removed from the iterator.
> 
> 
> Diffs
> -----
> 
>   security-admin/src/main/java/org/apache/ranger/biz/RangerTagDBRetriever.java 1b7e8b272 
> 
> 
> Diff: https://reviews.apache.org/r/73848/diff/1/
> 
> 
> Testing
> -------
> 
> Tested Manually by using bulk tags.
> 
> 
> Thanks,
> 
> Ankita Sinha
> 
>


Re: Review Request 73848: RANGER-3621 Optimise Tag/Policy iterator

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


Ship it!




Ship It!

- Madhan Neethiraj


On Feb. 18, 2022, 5:23 p.m., Ankita Sinha wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/73848/
> -----------------------------------------------------------
> 
> (Updated Feb. 18, 2022, 5:23 p.m.)
> 
> 
> Review request for ranger, Madhan Neethiraj and Subhrat Chaudhary.
> 
> 
> Bugs: RANGER-3621
>     https://issues.apache.org/jira/browse/RANGER-3621
> 
> 
> Repository: ranger
> 
> 
> Description
> -------
> 
> Optimise the logic of Tag and service-policies cache iterator
> 
> Problem Statement:
> Tags/policies in the iterator are not freed till the whole processing of all Tags/policies are done. So, in the case where there are lot of tag/policies, the performance can be impacted as the large number of tags/policies are held by iterator for long time. This causes performance degradation while retrieving the tags from db.
> 
> Solution:
> The individual tag/policy as soon as it is processed should be removed from the iterator.
> 
> 
> Diffs
> -----
> 
>   security-admin/src/main/java/org/apache/ranger/biz/RangerPolicyRetriever.java 4a8a5ee2d 
>   security-admin/src/main/java/org/apache/ranger/biz/RangerTagDBRetriever.java 1b7e8b272 
> 
> 
> Diff: https://reviews.apache.org/r/73848/diff/2/
> 
> 
> Testing
> -------
> 
> Tested Manually by using bulk data.
> 
> 
> Thanks,
> 
> Ankita Sinha
> 
>


Re: Review Request 73848: RANGER-3621 Optimise Tag iterator

Posted by Ankita Sinha <an...@freestoneinfotech.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/73848/
-----------------------------------------------------------

(Updated Feb. 18, 2022, 5:23 p.m.)


Review request for ranger, Madhan Neethiraj and Subhrat Chaudhary.


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


Repository: ranger


Description
-------

Optimise the logic of Tag iterator

Problem Statement:
Tags in the iterator are not freed till the whole processing of all Tags are done. So, in the case where there are lot of tag, the performance can be impacted as the large number of tags are held by iterator for long time. This causes performance degradation while retrieving the tags from db.

Solution:
The individual tag as soon as it is processed should be removed from the iterator.


Diffs (updated)
-----

  security-admin/src/main/java/org/apache/ranger/biz/RangerPolicyRetriever.java 4a8a5ee2d 
  security-admin/src/main/java/org/apache/ranger/biz/RangerTagDBRetriever.java 1b7e8b272 


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

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


Testing
-------

Tested Manually by using bulk tags.


Thanks,

Ankita Sinha


Re: Review Request 73848: RANGER-3621 Optimise Tag iterator

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


Ship it!




Ship It!

- Madhan Neethiraj


On Feb. 15, 2022, 12:57 p.m., Ankita Sinha wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/73848/
> -----------------------------------------------------------
> 
> (Updated Feb. 15, 2022, 12:57 p.m.)
> 
> 
> Review request for ranger, Madhan Neethiraj and Subhrat Chaudhary.
> 
> 
> Bugs: RANGER-3621
>     https://issues.apache.org/jira/browse/RANGER-3621
> 
> 
> Repository: ranger
> 
> 
> Description
> -------
> 
> Optimise the logic of Tag iterator
> 
> Problem Statement:
> Tags in the iterator are not freed till the whole processing of all Tags are done. So, in the case where there are lot of tag, the performance can be impacted as the large number of tags are held by iterator for long time. This causes performance degradation while retrieving the tags from db.
> 
> Solution:
> The individual tag as soon as it is processed should be removed from the iterator.
> 
> 
> Diffs
> -----
> 
>   security-admin/src/main/java/org/apache/ranger/biz/RangerTagDBRetriever.java 1b7e8b272 
> 
> 
> Diff: https://reviews.apache.org/r/73848/diff/1/
> 
> 
> Testing
> -------
> 
> Tested Manually by using bulk tags.
> 
> 
> Thanks,
> 
> Ankita Sinha
> 
>