----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/73556/#review223429 -----------------------------------------------------------
Ship it! Ship It! - Pradeep Agrawal On Aug. 29, 2021, 10:35 a.m., Kishor Gollapalliwar wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/73556/ > ----------------------------------------------------------- > > (Updated Aug. 29, 2021, 10:35 a.m.) > > > Review request for ranger, Dineshkumar Yadav, Abhay Kulkarni, Madhan > Neethiraj, Mehul Parikh, Pradeep Agrawal, Vishal Suvagia, and Velmurugan > Periasamy. > > > Bugs: RANGER-3385 > https://issues.apache.org/jira/browse/RANGER-3385 > > > Repository: ranger > > > Description > ------- > > Duplicate SQL prefix is allowed. Currently we need a manual human > intervention to find and correct. Use case in details as follows. > > # Use-Case: > > 1. Say user1 & user2 working on a fix in Ranger and they both need DB changes. > 2. Assume user1 needs to update table1 and user2 needs to update table2. > 3. Both Checked latest DB patch prefix (say it is 056-). And used prefix 057- > for their SQL files > > If both commits ends up merging. The setup script will apply ONLY one of the > both SQL files (prefixed 057-) randomly. > > # Reproduce Steps: > 1. cd <ranger-repo>/security-admin/db/mysql/patches > 2. Update prefix of last 2 patches such that both contains same prefix > 3. mvn clean compile package install -U #build ranger > 4. setup ranger > > To avoid this, we need to fail maven build itself if there are duplicate > prefix. > > > Diffs > ----- > > security-admin/pom.xml 032b79f1f > > > Diff: https://reviews.apache.org/r/73556/diff/1/ > > > Testing > ------- > > ## In-Valid cases > 1. Same prefixed files inside patches directory > 2. Same prefixed files inside audit directory > 3. Same prefixed files first inside patches second inside audit directory > > ## valid cases > 1. NO duplicate prefix > > ## build > mvn clean compile package install -U > > > Thanks, > > Kishor Gollapalliwar > >