----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/46962/#review133399 -----------------------------------------------------------
ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog240.java (line 44) <https://reviews.apache.org/r/46962/#comment197800> Use explicit imports. ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog240.java (line 267) <https://reviews.apache.org/r/46962/#comment197801> Use standard formatting with only a single space. ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog240.java (line 277) <https://reviews.apache.org/r/46962/#comment197805> Use javadoc instead of // comments. Also, the formatting in this function is not consistent in terms of spaces, especially near parentheses and curly braces. ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog240.java (line 312) <https://reviews.apache.org/r/46962/#comment197807> Catch NumberFormatException instead contrib/views/hive/src/main/java/org/apache/ambari/view/hive/resources/jobs/JobService.java (line 441) <https://reviews.apache.org/r/46962/#comment197810> Space after "," Same in 2 LOG statements below. - Alejandro Fernandez On May 16, 2016, 1:59 p.m., Nitiraj Rathore wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/46962/ > ----------------------------------------------------------- > > (Updated May 16, 2016, 1:59 p.m.) > > > Review request for Ambari, Alejandro Fernandez, DIPAYAN BHOWMICK, Gaurav > Nagar, Rohit Choudhary, and Ashwin Rajeev. > > > Bugs: AMBARI-16242 > https://issues.apache.org/jira/browse/AMBARI-16242 > > > Repository: ambari > > > Description > ------- > > Earlier : > the id for dynamic entity was created in the application with the use of > instance data for that view. This data is dependent on users and created > separate sequences for each user. So the id for one user was also generated > for other user. Hence the data in db of one user was getting overriden by > other user. > > In this patch : > Now the id is generated using table_sequence techique of JPA. table for > sequence is ambari_sequence. UpgradeCatalog240.java will add the current > sequence number for existing tables and for new table the sequence name will > be added automatically. As sequence size of 50 is provided for better > performances > > > Diffs > ----- > > > ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog240.java > dc8d9b7 > > ambari-server/src/main/java/org/apache/ambari/server/view/persistence/DataStoreImpl.java > 0ed260d > > contrib/views/hive/src/main/java/org/apache/ambari/view/hive/persistence/DataStoreStorage.java > 1e8f07f > > contrib/views/hive/src/main/java/org/apache/ambari/view/hive/resources/jobs/JobService.java > f7f883b > > contrib/views/pig/src/main/java/org/apache/ambari/view/pig/persistence/DataStoreStorage.java > 7ae7721 > > Diff: https://reviews.apache.org/r/46962/diff/ > > > Testing > ------- > > Following manual testing has been done. > 1. upgrade script creates correct current sequences. Done by manually > upgrading old ambari with existing views. Next job will allocate 50 more ids > 2. for new tables the entry in ambari_sequence is automatically added and the > ids will start from 1. > > > Thanks, > > Nitiraj Rathore > >