> On Nov. 16, 2016, 1:43 a.m., Jonathan Hurley wrote: > > ambari-server/src/main/java/org/apache/ambari/server/orm/entities/StatusHoldingEntity.java, > > lines 23-27 > > <https://reviews.apache.org/r/53686/diff/2/?file=1563883#file1563883line23> > > > > Documentation.
This is not part of the new patch. so droping this issue > On Nov. 16, 2016, 1:43 a.m., Jonathan Hurley wrote: > > ambari-server/src/main/java/org/apache/ambari/server/orm/entities/StageEntity.java, > > lines 232-237 > > <https://reviews.apache.org/r/53686/diff/2/?file=1563882#file1563882line232> > > > > NPE here? Isn't it impossible for a stage not to have a request? That > > would violate the DB. This is not part of the new patch. so droping this issue > On Nov. 16, 2016, 1:43 a.m., Jonathan Hurley wrote: > > ambari-server/src/main/java/org/apache/ambari/server/orm/entities/StageEntity.java, > > lines 231-237 > > <https://reviews.apache.org/r/53686/diff/2/?file=1563882#file1563882line231> > > > > This method isn't used externally - can we make it private or just > > integrate it directly into updateStatus() ? Otherwise it's possible to > > recalculate the request independant of setting the stage's status which > > seems wrong. This is not part of the new patch. so droping this issue > On Nov. 16, 2016, 1:43 a.m., Jonathan Hurley wrote: > > ambari-server/src/main/java/org/apache/ambari/server/orm/entities/StageEntity.java, > > line 227 > > <https://reviews.apache.org/r/53686/diff/2/?file=1563882#file1563882line227> > > > > I think this is where the biggest problem is. There's a reason that HRC > > and Stage collections are lazily fetched - it's because it doesn't come > > from JPA cache since it's an M2M entity relationship. It comes from the DB > > every time. > > > > This kind of call would destroy large, long-running orchestrations like > > upgrades. This is not part of the new patch. With new patch we are not fetching host role commands from stage/request entity So droping this issue > On Nov. 16, 2016, 1:43 a.m., Jonathan Hurley wrote: > > ambari-server/src/main/java/org/apache/ambari/server/orm/entities/HostRoleCommandEntity.java, > > lines 262-264 > > <https://reviews.apache.org/r/53686/diff/2/?file=1563880#file1563880line262> > > > > This line is concerned - how would stage be null? If it was, then the > > actual parent stage wouldn't have it's status updated. This is not part of the new patch. so droping this issue - Jaimin ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/53686/#review156009 ----------------------------------------------------------- On Dec. 7, 2016, 7:45 p.m., Jaimin Jetly wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/53686/ > ----------------------------------------------------------- > > (Updated Dec. 7, 2016, 7:45 p.m.) > > > Review request for Ambari, Jonathan Hurley, Nate Cole, and Sid Wagle. > > > Bugs: AMBARI-18868 > https://issues.apache.org/jira/browse/AMBARI-18868 > > > Repository: ambari > > > Description > ------- > > Stage and Request status should be persisted in the database. > > upgrading to ambari-3.0.0 should add status for all present stages and > request for the cluster. > > > Diffs > ----- > > > ambari-server/src/main/java/org/apache/ambari/server/actionmanager/ActionDBAccessorImpl.java > 2c87583 > > ambari-server/src/main/java/org/apache/ambari/server/actionmanager/ActionScheduler.java > e80b020 > > ambari-server/src/main/java/org/apache/ambari/server/actionmanager/Request.java > 31e11c1 > > ambari-server/src/main/java/org/apache/ambari/server/actionmanager/Stage.java > 319d72d > > ambari-server/src/main/java/org/apache/ambari/server/controller/internal/CalculatedStatus.java > 3c415df > > ambari-server/src/main/java/org/apache/ambari/server/events/TaskUpdateEvent.java > PRE-CREATION > > ambari-server/src/main/java/org/apache/ambari/server/events/listeners/tasks/TaskUpdateListener.java > PRE-CREATION > > ambari-server/src/main/java/org/apache/ambari/server/events/publishers/TaskUpdateEventPublisher.java > PRE-CREATION > > ambari-server/src/main/java/org/apache/ambari/server/orm/dao/HostRoleCommandDAO.java > 02c4091 > > ambari-server/src/main/java/org/apache/ambari/server/orm/dao/RequestDAO.java > 1c4d0a3 > ambari-server/src/main/java/org/apache/ambari/server/orm/dao/StageDAO.java > d2f899f > > ambari-server/src/main/java/org/apache/ambari/server/orm/entities/RequestEntity.java > b1aad00 > > ambari-server/src/main/java/org/apache/ambari/server/orm/entities/StageEntity.java > f9c8810 > > ambari-server/src/main/java/org/apache/ambari/server/orm/entities/StageEntityPK.java > 0c227bc > > ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog300.java > 4f90ef3 > ambari-server/src/main/resources/Ambari-DDL-Derby-CREATE.sql 8cf2c0d > ambari-server/src/main/resources/Ambari-DDL-MySQL-CREATE.sql 82ce31e > ambari-server/src/main/resources/Ambari-DDL-Oracle-CREATE.sql e2c2dd5 > ambari-server/src/main/resources/Ambari-DDL-Postgres-CREATE.sql 4e9a535 > ambari-server/src/main/resources/Ambari-DDL-SQLAnywhere-CREATE.sql 0ba7df6 > ambari-server/src/main/resources/Ambari-DDL-SQLServer-CREATE.sql d8cad6f > > ambari-server/src/test/java/org/apache/ambari/server/actionmanager/TestActionScheduler.java > f86c02e > > ambari-server/src/test/java/org/apache/ambari/server/controller/internal/UpgradeResourceProviderTest.java > 8efcc61 > > ambari-server/src/test/java/org/apache/ambari/server/controller/internal/UpgradeSummaryResourceProviderTest.java > baec7df > > ambari-server/src/test/java/org/apache/ambari/server/events/listeners/tasks/TaskUpdateListenerTest.java > PRE-CREATION > > ambari-server/src/test/java/org/apache/ambari/server/orm/dao/UpgradeDAOTest.java > cc49cbd > > ambari-server/src/test/java/org/apache/ambari/server/state/services/RetryUpgradeActionServiceTest.java > 2fb57d7 > > ambari-server/src/test/java/org/apache/ambari/server/upgrade/UpgradeCatalog300Test.java > d7979e8 > > Diff: https://reviews.apache.org/r/53686/diff/ > > > Testing > ------- > > Verified manually on a cluster by making api requests and upgrading ambari. > Add unit tests. > Jenkins job overall unit test result pending.. > > > Thanks, > > Jaimin Jetly > >