Skip to main content
Open

Retry on deadlock

Related products:Software FactoryWindows GUIUniversal GUIIndicium Service Tier
Ester
Robert Jan de Nie
Eric Franken
+20
  • Ester
    Ester
  • Robert Jan de Nie
    Robert Jan de Nie
  • Andre te Raa
  • Roland van Aggele
  • Eric Franken
    Eric Franken
  • Maurice Liebregt
  • Robbert van Tongeren
    Robbert van Tongeren
  • Bart Koning
    Bart Koning
  • gariens
  • Jaap van Beusekom
    Jaap van Beusekom
  • Hugo Nienhuis
    Hugo Nienhuis
  • Freddy
    Freddy
  • Frank Junger
  • Dick Schäfer
  • Ricky
    Ricky
  • Arie V
    Arie V
  • J. de Lange
    J. de Lange
  • mperrott
    mperrott
  • Jan Egbert Muurman
  • Suleyman
  • Marc Ferket
  • Sergio G Santjes
  • HarryA
  • Marius Korff
    Marius Korff
  • Hans Pot

Robert Jan de Nie
Thinkwise blogger

When a user currently encounters a deadlock and she is chosen as the deadlock-victim, the user gets a message asking to rerun the transaction.

Solving (frequent) deadlocks is something a developer should do, but they still can happen. Often, when a user retries to run the transaction, the problem has gone away.

I’d like to propose a client side (GUI/Indicium) solution that will re-try the transaction without the user intervening. This way, the user is not seeing a technical message regarding the deadlock and the action the user wanted to make still pulls trough.

I would implement this as follows (my suggestion)

  • Store a setting in SF specifying the amount of deadlock retries (default = 5)
  • GUI/Indicium:
    • Retry the transaction as many times as specified in SF (with an appropriate wait-time)
    • When a deadlock occurs, store the deadlock graph XML in a deadlock-log table in IAM
    • Write to logfile a deadlock has occured (warning)

The advantage to this solution is two-fold:

  • The user can (mostly) continue their work and is not bothered by ‘scary’ deadlock messages
  • The developer/administrator has insight in how many deadlocks happen and has got a log of deadlock graphs to look at.
Did this topic help you find an answer to your question?

2 replies

Jeroen van den Belt
Administrator
Forum|alt.badge.img+9
Updated idea status NewOpen

Hugo Nienhuis
Superhero
Forum|alt.badge.img+12

Bump ;-)

Especially for indicium, since we are using more and more system flows now. Sql server returns an error message 1205 in case of a deadlock but this remains unseen since it is only stored in the indicium logs. Users will not be aware of the deadlock.


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings