-
Bug
-
Resolution: Done
-
Major
-
None
-
None
-
None
-
False
-
None
-
False
-
NEW
-
NEW
-
2022 Week 26-28 (from Jun 27), 2022 Week 29-31 (from Jul 18)
Under heavy stress tests, the following error has been observed
Caused by: com.microsoft.sqlserver.jdbc.SQLServerException: Transaction (Process ID 1649) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction.
We should evaluate to include the fix in the current script we provide for SQL Server:
The DDL script (sqlserver-jbpm-schema.sql) creates 2 indexes on EventTypes table:
I. create index IDX_EventTypes_Id ON EventTypes(InstanceId);
II. create index IDX_EventTypes_element ON EventTypes(element);
It seems that the second one is completely useless, since there are only SELECTs using InstanceId, INSERTs and DELETEs (“delete from EventTypes where InstanceId=? and element=?”), while there is no PK or an index that combines both database columns (“InstanceId” and “element”).
As per the customer, after creating a new index on both “InstanceId” and “element” the deadlocks completely disappeared. Also the performance of the delete statement was significantly improved."
- clones
-
RHPAM-4253 Current index settings might cause DeadLocks in SQL Server
- Closed