> On 八月 22, 2017, 9:31 p.m., Don Bosco Durai wrote:
> > agents-audit/src/main/java/org/apache/ranger/audit/destination/HDFSAuditDestination.java
> > Lines 203 (patched)
> > <https://reviews.apache.org/r/61809/diff/1/?file=1801337#file1801337line206>
> >
> > Not sure whether moving the logger.info will help in performance
> > improvement. Are you using any metrics to see whether this change is really
> > improving the performance?
> >
> > Thanks
Ok. The length of the execution time of the sync block will affect the
performance of large data execution in parallel. In the case of large data
volume, I carefully tested the impact of logger.info on performance. Such as
RANGER-1729, performance is now reduced by 2.75%, when adding two logger.info
in evaluateAccess function, the performance will be significantly reduced to
36%. Please refer to verify_patch_result_detail.png.
ColumnFamilyAccessResult evaluateAccess(String operation, Action action, final
RegionCoprocessorEnvironment env,
final Map<byte[], ? extends Collection<?>> familyMap) throws
AccessDeniedException {
LOG.info("===>Enter evaluateAccess.");
......
LOG.info("===>exit evaluateAccess.");
}
Functionally, the following statement has the same functions when it is inside
the sync block and outside the sync block. But the execution time of the sync
block will be different.
logger.info("Flush HDFS audit logs completed.....");
- Qiang
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/61809/#review183530
-----------------------------------------------------------
On 八月 22, 2017, 3:14 a.m., Qiang Zhang wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/61809/
> -----------------------------------------------------------
>
> (Updated 八月 22, 2017, 3:14 a.m.)
>
>
> Review request for ranger, Alok Lal, Ankita Sinha, Don Bosco Durai, Colm O
> hEigeartaigh, Gautam Borad, Madhan Neethiraj, Ramesh Mani, Selvamohan
> Neethiraj, and Velmurugan Periasamy.
>
>
> Bugs: RANGER-1745
> https://issues.apache.org/jira/browse/RANGER-1745
>
>
> Repository: ranger
>
>
> Description
> -------
>
> From the performance and code logic analysis, we should optimize the flush
> function of HDFSAuditDestination class. The reason is as following:
> 1. Its logic is not clear. There are duplicate code and repeated judgment.
> 2. Through my tests, in the case of large data, the log io will have a big
> impact on performance.
>
>
> Diffs
> -----
>
>
> agents-audit/src/main/java/org/apache/ranger/audit/destination/HDFSAuditDestination.java
> 66d8504
>
>
> Diff: https://reviews.apache.org/r/61809/diff/1/
>
>
> Testing
> -------
>
>
> Thanks,
>
> Qiang Zhang
>
>