-
Notifications
You must be signed in to change notification settings - Fork 0
Description
When executing rules in the Saved Signoff page, users may encounter an unhelpful EJBTransactionRollbcckException error message as pictured:
We need to either improve the error message to indicate more precisely the problem, else remove the constraint check causing the database transaction rollback.
The underlying cause is:
java.sql.SQLIntegrityConstraintViolationException: ORA-00001: unique constraint (SRM_OWNER.GROUP_SIGNOFF_HISTORY_AK1) violated
Which is the constraint defined here:
srm/container/oracle/initdb.d/02_ddl.sql
Line 287 in f91e6a8
| CONSTRAINT GROUP_SIGNOFF_HISTORY_AK1 UNIQUE (GROUP_ID,SYSTEM_ID,COMPONENT_ID,MODIFIED_DATE) |
This constraint effectively says that you can't modify a group's component signoff more than once a second.
The Saved Signoff page allows admins to define rules to quickly modify group component signoff in bulk very quickly. If any of the rules overlap, then an attempt to update a group's component signoff more than once a wall-clock second may occur. In the provided screenshot notice the duplicate rule on the System CLAS12 ALERT AHDC. The two rules for that System actually do vary by group, one for each of the two groups, but downgrade cascade behavior results in the last group being updated twice.
Reported by: moser