Issue
When you save two history entries for the same case at the same time from different nodes, duplicate key exceptions are seen in logs.
Symptoms and Impact
This issue causes duplicate key exception which may prevent assignments from being submitted because the commit fails.
Steps to reproduce
- Create a case type that includes at least one step that generates history.
- Create an activity that adds a history record to an instance of the case type via the History-Add method.
- Create a case of the case type.
- Have one user perform the step which will generate history.
- On another node, have another user or a background process execute the activity which uses the History-Add method within the same millisecond.
Root Cause
A limitation in the History-Add method which cannot ensure uniqueness for records that are created for the same case within the same millisecond on different nodes.
Solution
An enhancement request has been raised to address this limitation but it has not yet been assigned to a specific release. This known issue will be updated with release details when the enhancement for this issue is available.