An Application Tuning Case Study: The Deadly Deadlock
By gaurav.verma on Feb 05, 2007
Lets face it. Deadlock and Latching issues have always been hard to
debug. Many a times, we don't focus too well on application tuning,
even though, it always advisable to look at the application design and
user access trends first. These things don't come to the mind too
Many a times, we do face situations where the users are
deadlocked, sitting and watching blue screens or the application was
freezing up. While there are many reasons for this to happen: Poor OS
implementation, (swapping/disk/Memory issues) , RDBMS bugs, RDBMS
initialization parameter values, having a lot of non sharable SQL, a
good share of cases can also be caused due to Poor application coding,
without undertanding the sequence in which resources should be accessed
or acted upon (updated/deleted etc).
This is one such case study in which a deadlock was traced
back to a deadlock situation un-aware code and the solution was to
enhance the code to not cause deadlocks in the future. While the change
was really simple, picturizing the deadlock in action was really
This article also goes into the mechanics of contructing the
deadlock situation in slow motion. This makes it an instructive case
study to read through for future reference.
Read the entire case study here...