Bug #21356 Change lock priority so that the transaction holding S-lock gets X-lock first
Submitted: 31 Jul 2006 5:34 Modified: 13 May 2010 16:03
Reporter: Heikki Tuuri Email Updates:
Status: Verified Impact on me:
Category:MySQL Server: InnoDB storage engine Severity:S4 (Feature request)
Version:All OS:Any (All)
Assigned to: Sunny Bains CPU Architecture:Any
Triage: Triaged: D5 (Feature request)

[31 Jul 2006 5:34] Heikki Tuuri
This comes from Sinisa and Valeriy:

if a transaction T1 has an S-lock on a row and T1 wants to get an X-lock on the row, then the X-lock request should overtake an X-lock request by transaction T2 that does NOT have an S-lock on the row.

Note that we must be very careful that this does not break deadlock detection in lock0lock.c.

Note also that we cannot grant the X-lock if some transaction T3 is holding an S-lock.

How to repeat:
[16 Apr 2007 12:06] Heikki Tuuri
This is essentially a feature request.