You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ranger.apache.org by Mehul Parikh <me...@freestoneinfotech.com> on 2016/07/23 11:42:23 UTC

Review Request 50375: RANGER-1120 : Need a java patch to handle upgrade of hive servicedef

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

Review request for ranger, Gautam Borad, Madhan Neethiraj, Pradeep Agrawal, Ramesh Mani, and Velmurugan Periasamy.


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


Repository: ranger


Description
-------

**Problem Statement**
In order to allow users migrating to 0.6 version of Ranger from earlier version to use row level filtering policies and column masking policies, Need to have a JAVA patch that migrates servicedef to have default values defined in hive servicedef.
**Proposed Solution**
In order to populate default configs for datamask and rowfilter objects in HiveServiceDef, I have added the java patch that will read those objects from json and add it to the databse.


Diffs
-----

  agents-common/src/main/java/org/apache/ranger/plugin/store/EmbeddedServiceDefsUtil.java 2002295 
  security-admin/src/main/java/org/apache/ranger/patch/PatchForHiveServiceDefUpdate_J10006.java PRE-CREATION 

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


Testing
-------

**Verified :**
1) Upgraded Ranger from 0.5 to 0.6 successfully.
2) After upgrade hive shows all three tabs for policy types i.e. Access,Masking and Row Level Filter
3) Checked for all HIVE issues reported in Jira. None of them are reproducible (check the screenshots attached)
4) Policy enforcement works as expected


Thanks,

Mehul Parikh


Re: Review Request 50375: RANGER-1120 : Need a java patch to handle upgrade of hive servicedef

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




security-admin/src/main/java/org/apache/ranger/patch/PatchForHiveServiceDefUpdate_J10006.java (line 140)
<https://reviews.apache.org/r/50375/#comment209176>

    dbHiveServiceDef could be null - based on "if"s in line #133 & #137. I would suggest to keep lines #133 to #146 within "if(dbHiveServiceDef != null)".


- Madhan Neethiraj


On July 23, 2016, 11:42 a.m., Mehul Parikh wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/50375/
> -----------------------------------------------------------
> 
> (Updated July 23, 2016, 11:42 a.m.)
> 
> 
> Review request for ranger, Gautam Borad, Madhan Neethiraj, Pradeep Agrawal, Ramesh Mani, and Velmurugan Periasamy.
> 
> 
> Bugs: RANGER-1120
>     https://issues.apache.org/jira/browse/RANGER-1120
> 
> 
> Repository: ranger
> 
> 
> Description
> -------
> 
> **Problem Statement**
> In order to allow users migrating to 0.6 version of Ranger from earlier version to use row level filtering policies and column masking policies, Need to have a JAVA patch that migrates servicedef to have default values defined in hive servicedef.
> **Proposed Solution**
> In order to populate default configs for datamask and rowfilter objects in HiveServiceDef, I have added the java patch that will read those objects from json and add it to the databse.
> 
> 
> Diffs
> -----
> 
>   agents-common/src/main/java/org/apache/ranger/plugin/store/EmbeddedServiceDefsUtil.java 2002295 
>   security-admin/src/main/java/org/apache/ranger/patch/PatchForHiveServiceDefUpdate_J10006.java PRE-CREATION 
> 
> Diff: https://reviews.apache.org/r/50375/diff/
> 
> 
> Testing
> -------
> 
> **Verified :**
> 1) Upgraded Ranger from 0.5 to 0.6 successfully.
> 2) After upgrade hive shows all three tabs for policy types i.e. Access,Masking and Row Level Filter
> 3) Checked for all HIVE issues reported in Jira. None of them are reproducible (check the screenshots attached)
> 4) Policy enforcement works as expected
> 
> 
> Thanks,
> 
> Mehul Parikh
> 
>


Re: Review Request 50375: RANGER-1120 : Need a java patch to handle upgrade of hive servicedef

Posted by Velmurugan Periasamy <vp...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/50375/#review143439
-----------------------------------------------------------




security-admin/src/main/java/org/apache/ranger/patch/PatchForHiveServiceDefUpdate_J10006.java (line 127)
<https://reviews.apache.org/r/50375/#comment209227>

    Will this fail installs where Hive service def is not available genuinely? (i.e. ranger.supportedcomponents property does not contain hive)


- Velmurugan Periasamy


On July 23, 2016, 11:42 a.m., Mehul Parikh wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/50375/
> -----------------------------------------------------------
> 
> (Updated July 23, 2016, 11:42 a.m.)
> 
> 
> Review request for ranger, Gautam Borad, Madhan Neethiraj, Pradeep Agrawal, Ramesh Mani, and Velmurugan Periasamy.
> 
> 
> Bugs: RANGER-1120
>     https://issues.apache.org/jira/browse/RANGER-1120
> 
> 
> Repository: ranger
> 
> 
> Description
> -------
> 
> **Problem Statement**
> In order to allow users migrating to 0.6 version of Ranger from earlier version to use row level filtering policies and column masking policies, Need to have a JAVA patch that migrates servicedef to have default values defined in hive servicedef.
> **Proposed Solution**
> In order to populate default configs for datamask and rowfilter objects in HiveServiceDef, I have added the java patch that will read those objects from json and add it to the databse.
> 
> 
> Diffs
> -----
> 
>   agents-common/src/main/java/org/apache/ranger/plugin/store/EmbeddedServiceDefsUtil.java 2002295 
>   security-admin/src/main/java/org/apache/ranger/patch/PatchForHiveServiceDefUpdate_J10006.java PRE-CREATION 
> 
> Diff: https://reviews.apache.org/r/50375/diff/
> 
> 
> Testing
> -------
> 
> **Verified :**
> 1) Upgraded Ranger from 0.5 to 0.6 successfully.
> 2) After upgrade hive shows all three tabs for policy types i.e. Access,Masking and Row Level Filter
> 3) Checked for all HIVE issues reported in Jira. None of them are reproducible (check the screenshots attached)
> 4) Policy enforcement works as expected
> 
> 
> Thanks,
> 
> Mehul Parikh
> 
>


Re: Review Request 50375: RANGER-1120 : Need a java patch to handle upgrade of hive servicedef

Posted by Velmurugan Periasamy <vp...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/50375/#review143581
-----------------------------------------------------------


Ship it!




Ship It!

- Velmurugan Periasamy


On July 26, 2016, 9:23 a.m., Mehul Parikh wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/50375/
> -----------------------------------------------------------
> 
> (Updated July 26, 2016, 9:23 a.m.)
> 
> 
> Review request for ranger, Gautam Borad, Madhan Neethiraj, Pradeep Agrawal, Ramesh Mani, and Velmurugan Periasamy.
> 
> 
> Bugs: RANGER-1120
>     https://issues.apache.org/jira/browse/RANGER-1120
> 
> 
> Repository: ranger
> 
> 
> Description
> -------
> 
> **Problem Statement**
> In order to allow users migrating to 0.6 version of Ranger from earlier version to use row level filtering policies and column masking policies, Need to have a JAVA patch that migrates servicedef to have default values defined in hive servicedef.
> **Proposed Solution**
> In order to populate default configs for datamask and rowfilter objects in HiveServiceDef, I have added the java patch that will read those objects from json and add it to the databse.
> 
> 
> Diffs
> -----
> 
>   agents-common/src/main/java/org/apache/ranger/plugin/store/EmbeddedServiceDefsUtil.java 2002295 
>   security-admin/src/main/java/org/apache/ranger/patch/PatchForHiveServiceDefUpdate_J10006.java PRE-CREATION 
> 
> Diff: https://reviews.apache.org/r/50375/diff/
> 
> 
> Testing
> -------
> 
> **Verified :**
> 1) Upgraded Ranger from 0.5 to 0.6 successfully.
> 2) After upgrade hive shows all three tabs for policy types i.e. Access,Masking and Row Level Filter
> 3) Checked for all HIVE issues reported in Jira. None of them are reproducible (check the screenshots attached)
> 4) Policy enforcement works as expected
> 
> 
> Thanks,
> 
> Mehul Parikh
> 
>


Re: Review Request 50375: RANGER-1120 : Need a java patch to handle upgrade of hive servicedef

Posted by Mehul Parikh <me...@freestoneinfotech.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/50375/
-----------------------------------------------------------

(Updated July 26, 2016, 9:23 a.m.)


Review request for ranger, Gautam Borad, Madhan Neethiraj, Pradeep Agrawal, Ramesh Mani, and Velmurugan Periasamy.


Changes
-------

Handled both the review comments and verified Ranger installation with HiveServicedef and also without HiveServiceDef.


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


Repository: ranger


Description
-------

**Problem Statement**
In order to allow users migrating to 0.6 version of Ranger from earlier version to use row level filtering policies and column masking policies, Need to have a JAVA patch that migrates servicedef to have default values defined in hive servicedef.
**Proposed Solution**
In order to populate default configs for datamask and rowfilter objects in HiveServiceDef, I have added the java patch that will read those objects from json and add it to the databse.


Diffs (updated)
-----

  agents-common/src/main/java/org/apache/ranger/plugin/store/EmbeddedServiceDefsUtil.java 2002295 
  security-admin/src/main/java/org/apache/ranger/patch/PatchForHiveServiceDefUpdate_J10006.java PRE-CREATION 

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


Testing
-------

**Verified :**
1) Upgraded Ranger from 0.5 to 0.6 successfully.
2) After upgrade hive shows all three tabs for policy types i.e. Access,Masking and Row Level Filter
3) Checked for all HIVE issues reported in Jira. None of them are reproducible (check the screenshots attached)
4) Policy enforcement works as expected


Thanks,

Mehul Parikh