Hello,
I am using Hibernate to access a DB2 database. When running the application on active-active cluster, I am seeing an exception with SQLSTATE of 40001 indicating "Deadlock or timeout with automatic rollback occurred."
It is occuring while updating a commonly used table entry, since other transactions in progress may be locking the entry for update.
There is a SET CURRENT LOCK TIMEOUT on DB2 to increase the timeout value.
Could someone please tell me how to set this CURRENT LOCK TIMEOUT from Hibernate? Is there a property in properties file or a method on Session or Connection class, that I can use? Basically I need the timeout to be a high value such as 60 seconds etc?
I would really appreciate your help.
Thanks,
Priya
|