-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/53068/
-----------------------------------------------------------
Review request for Ambari, Nate Cole and Robert Levas.
Bugs: AMBARI-18652
https://issues.apache.org/jira/browse/AMBARI-18652
Repository: ambari
Description
-------
There is a JPA timing issue WRT to updating alert targets where lazy loaded
lists outside of a transaction cause the data set on the {{AlertTargetEnity}}
to be refreshed from the database.
While maintaining the bi-directional relationship between {{AlertTargetEntity}}
and {{AlertGroupEntity}}, and {{IndirectSet}} from JPA causes JPA to detect a
stale entity from another transaction.
STR:
It's more likely to happen when there are active alerts.
- Create a new alert target for _just_ HDFS
- Shut down HDFS
- Try to edit the name of the alert target
It will return a 200 return code, but the data will not have changed.
Diffs
-----
ambari-server/src/main/java/org/apache/ambari/server/controller/internal/AlertTargetResourceProvider.java
48a5183
ambari-server/src/main/java/org/apache/ambari/server/orm/entities/AlertGroupEntity.java
0d6d151
ambari-server/src/main/java/org/apache/ambari/server/orm/entities/AlertTargetEntity.java
de21f2d
ambari-server/src/test/java/org/apache/ambari/server/controller/internal/AlertTargetResourceProviderTest.java
bcdb9ce
Diff: https://reviews.apache.org/r/53068/diff/
Testing
-------
Tests run: 4689, Failures: 0, Errors: 0, Skipped: 42
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 29:00 min
[INFO] Finished at: 2016-10-20T12:37:48-04:00
[INFO] Final Memory: 57M/702M
[INFO] ------------------------------------------------------------------------
Thanks,
Jonathan Hurley