----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/57114/#review166975 -----------------------------------------------------------
hive-agent/src/main/java/org/apache/ranger/authorization/hive/authorizer/RangerHiveAuthorizer.java (line 562) <https://reviews.apache.org/r/57114/#comment239075> columnTransformers will have as many entries as hiveObj.getColumns() - irrespective of whether column masking is added or not for any column. Consider refactoring getCellValueTransformer(): - to return RangerDataMaskResult - move rest of the code to a new method, which will return 'columnTransformer' from the result needToTransform can be set with the following: if(isDataMaskEnabled(dataMaskResult)) { needToTransform = true; } Similar refactoring for getRowFilterExpression() as well. - Madhan Neethiraj On Feb. 27, 2017, 11:22 p.m., Abhay Kulkarni wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/57114/ > ----------------------------------------------------------- > > (Updated Feb. 27, 2017, 11:22 p.m.) > > > Review request for ranger, Madhan Neethiraj and Velmurugan Periasamy. > > > Bugs: RANGER-1414 > https://issues.apache.org/jira/browse/RANGER-1414 > > > Repository: ranger > > > Description > ------- > > Ranger Hive authorizer implementation of applyRowFilterAndColumnMasking() API > returns all privileged objects given to it as argument. It is modified to > return only those objects to which row-filter/column-mask apply per Ranger > policies. > > > Diffs > ----- > > > hive-agent/src/main/java/org/apache/ranger/authorization/hive/authorizer/RangerHiveAuthorizer.java > cb94f19 > > Diff: https://reviews.apache.org/r/57114/diff/ > > > Testing > ------- > > Ran all unit tests. > > > Thanks, > > Abhay Kulkarni > >
