Is there a way to prevent deadlocks in a dialog or possibly catch them before they occur?
book
Article ID: 201837
calendar_today
Updated On:
Products
IDMSIDMS - DatabaseIDMS - ADS
Issue/Introduction
Is there a way to prevent deadlocks in a dialog or possibly catch them before they occur? 0092220 14.05.58 IDMS DC001000 V125 T13 T:000024950 MIAPPL P:MIP009 C:DEAD WAITING ON R:LTXNLOCK 00000008 022E1701 0092220 14.05.58 IDMS DC001000 V125 T13 T:000024951 MIAPPL P:MIP009 C:DEAD WAITING ON R:LTXNLOCK 00002008 00022E17 0092220 14.05.58 IDMS DC001002 V125 T13 T:000024951 MIAPPL P:MIP009 C:DEAD DEADLOCKED ON R:LTXNLOCK 00002008 00022E17
Environment
Release : 19.0
Component : CA IDMS/DB
Resolution
To avoid the deadlocks you could write two Cobol programs, one to exclusively enqueue a resource id using NOWAIT. Using WAIT would cause enqueue deadlocks.
Check for error status 3901:
At least one requested resource cannot be enqueued immediately; to wait would cause a deadlock. No new resources have been acquired.
Error status 0000 means it was successful.
If it receives a 3901 the program would retry in a loop until it is successful.
You would need another program to simply dequeue the resource id.
All dialogs doing put and get queue will call the enqueue program first and after the put/get queue is done then call the dequeue program.