ranger-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Pradeep Agrawal <pradeepagrawal8...@gmail.com>
Subject Review Request 70614: RANGER-2419: Improve sql script to skip statements when atlas service def is not supported
Date Thu, 09 May 2019 08:06:24 GMT

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

Review request for ranger, Ankita Sinha, bhavik patel, Gautam Borad, Abhay Kulkarni, Madhan
Neethiraj, Mehul Parikh, Nikhil P, Nitin Galave, Ramesh Mani, Sailaja Polavarapu, and Velmurugan
Periasamy.


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


Repository: ranger


Description
-------

**Problem Description:** If previous version of ranger(<=0.6) is installed without atlas
service def then upgrading ranger to higher version may fail because statement https://github.com/hortonworks/ranger/blob/HDF-3.4.0.0/security-admin/db/oracle/patches/035-update-schema-for-x-policy.sql#L208
will return no results and oracle pl/sql engine doesn't handle it internally.

**Proposed solution:** First check if any record exist then only load the record in internal
variable.


Diffs
-----

  security-admin/db/oracle/patches/035-update-schema-for-x-policy.sql 3afdf47d8 


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


Testing
-------

**Steps performed to test the patch on Ranger-admin**

To reproduce the case first installed ranger-0.6 for oracle db flavor. In install.properties
file provided below values for the properties policymgr_supportedcomponents => hdfs,hive,hbase,knox,storm

Now from the master branch.
Created Build with patch and untar the build.
Opened install.properties and provided db configuration in install.properties which was provided
in ranger-0.6 branch build.
Called setup.sh
Ranger setup process shall try to apply the new db patches.

**Expected Behaviour:**
Ranger installation should proceed without db patch 035 failure
**Actual Behaviour:**
Ranger installation finished successfully without db patch 035 failure.


Thanks,

Pradeep Agrawal


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message