Re: Review Request 62726: Some ResourceProviders Are Not Transactional
--- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/62726/#review186937 --- Ship it! Ship It! - Dmitro Lisnichenko On Oct. 2, 2017, 5:54 p.m., Nate Cole wrote: > > --- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/62726/ > --- > > (Updated Oct. 2, 2017, 5:54 p.m.) > > > Review request for Ambari, Dmitro Lisnichenko and Jonathan Hurley. > > > Bugs: AMBARI-22110 > https://issues.apache.org/jira/browse/AMBARI-22110 > > > Repository: ambari > > > Description > --- > > While investigating an issue with VDFs which don't contain any OS's which > match the cluster, it was observed that, even after throwing an Exception > inside of a Transaction, the entities created inside that transaction were > being committed. > Eventual investigation led to a problem between Guice/AOP and our > ResourceProviders. The Guice documentations says that @Transactional methods > can only be intercepted on objects created by Guice: > > > Diffs > - > > > ambari-server/src/main/java/org/apache/ambari/server/controller/ControllerModule.java > e3f1458202 > > ambari-server/src/main/java/org/apache/ambari/server/controller/ResourceProviderFactory.java > 9cd1d745c6 > > ambari-server/src/main/java/org/apache/ambari/server/controller/internal/AbstractControllerResourceProvider.java > 0782685d07 > > ambari-server/src/main/java/org/apache/ambari/server/controller/internal/AlertTargetResourceProvider.java > 0b7f1db9c9 > > ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ClientConfigResourceProvider.java > 9d2b39effc > > ambari-server/src/main/java/org/apache/ambari/server/controller/internal/DefaultProviderModule.java > 781b01525f > > ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ViewInstanceResourceProvider.java > 63e6c24fc8 > > > Diff: https://reviews.apache.org/r/62726/diff/1/ > > > Testing > --- > > Manual. Automated: > > [INFO] Results: > [INFO] > [WARNING] Tests run: 4914, Failures: 0, Errors: 0, Skipped: 34 > [INFO] > > [INFO] > > [INFO] BUILD SUCCESS > [INFO] > > [INFO] Total time: 24:53.576s > [INFO] Finished at: Mon Oct 02 11:20:47 EDT 2017 > [INFO] Final Memory: 78M/1941M > [INFO] > > > > Thanks, > > Nate Cole > >
Re: Review Request 62726: Some ResourceProviders Are Not Transactional
--- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/62726/#review186867 --- Ship it! I wish we could add comments somewhere visible which guards against this awful anti-pattern of not using the factory ... so many side-effects at runtime from transactions not being started. Ugh.. - Jonathan Hurley On Oct. 2, 2017, 10:54 a.m., Nate Cole wrote: > > --- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/62726/ > --- > > (Updated Oct. 2, 2017, 10:54 a.m.) > > > Review request for Ambari, Dmitro Lisnichenko and Jonathan Hurley. > > > Bugs: AMBARI-22110 > https://issues.apache.org/jira/browse/AMBARI-22110 > > > Repository: ambari > > > Description > --- > > While investigating an issue with VDFs which don't contain any OS's which > match the cluster, it was observed that, even after throwing an Exception > inside of a Transaction, the entities created inside that transaction were > being committed. > Eventual investigation led to a problem between Guice/AOP and our > ResourceProviders. The Guice documentations says that @Transactional methods > can only be intercepted on objects created by Guice: > > > Diffs > - > > > ambari-server/src/main/java/org/apache/ambari/server/controller/ControllerModule.java > e3f1458202 > > ambari-server/src/main/java/org/apache/ambari/server/controller/ResourceProviderFactory.java > 9cd1d745c6 > > ambari-server/src/main/java/org/apache/ambari/server/controller/internal/AbstractControllerResourceProvider.java > 0782685d07 > > ambari-server/src/main/java/org/apache/ambari/server/controller/internal/AlertTargetResourceProvider.java > 0b7f1db9c9 > > ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ClientConfigResourceProvider.java > 9d2b39effc > > ambari-server/src/main/java/org/apache/ambari/server/controller/internal/DefaultProviderModule.java > 781b01525f > > ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ViewInstanceResourceProvider.java > 63e6c24fc8 > > > Diff: https://reviews.apache.org/r/62726/diff/1/ > > > Testing > --- > > Manual. Automated: > > [INFO] Results: > [INFO] > [WARNING] Tests run: 4914, Failures: 0, Errors: 0, Skipped: 34 > [INFO] > > [INFO] > > [INFO] BUILD SUCCESS > [INFO] > > [INFO] Total time: 24:53.576s > [INFO] Finished at: Mon Oct 02 11:20:47 EDT 2017 > [INFO] Final Memory: 78M/1941M > [INFO] > > > > Thanks, > > Nate Cole > >
Review Request 62726: Some ResourceProviders Are Not Transactional
--- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/62726/ --- Review request for Ambari, Dmitro Lisnichenko and Jonathan Hurley. Bugs: AMBARI-22110 https://issues.apache.org/jira/browse/AMBARI-22110 Repository: ambari Description --- While investigating an issue with VDFs which don't contain any OS's which match the cluster, it was observed that, even after throwing an Exception inside of a Transaction, the entities created inside that transaction were being committed. Eventual investigation led to a problem between Guice/AOP and our ResourceProviders. The Guice documentations says that @Transactional methods can only be intercepted on objects created by Guice: Diffs - ambari-server/src/main/java/org/apache/ambari/server/controller/ControllerModule.java e3f1458202 ambari-server/src/main/java/org/apache/ambari/server/controller/ResourceProviderFactory.java 9cd1d745c6 ambari-server/src/main/java/org/apache/ambari/server/controller/internal/AbstractControllerResourceProvider.java 0782685d07 ambari-server/src/main/java/org/apache/ambari/server/controller/internal/AlertTargetResourceProvider.java 0b7f1db9c9 ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ClientConfigResourceProvider.java 9d2b39effc ambari-server/src/main/java/org/apache/ambari/server/controller/internal/DefaultProviderModule.java 781b01525f ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ViewInstanceResourceProvider.java 63e6c24fc8 Diff: https://reviews.apache.org/r/62726/diff/1/ Testing --- Manual. Automated pending. Thanks, Nate Cole