MySQL Locks: order of unblocked threads
Posted
by teehoo
on Stack Overflow
See other posts from Stack Overflow
or by teehoo
Published on 2010-05-22T18:24:18Z
Indexed on
2010/05/22
18:30 UTC
Read the original article
Hit count: 219
I have a MySQL ISAM table being accessed my multiple php instances. Right now I'm using a WRITE
lock to serialize access to this table.
My question is how do I ensure that the PHP instances get served on a First-Come-First-Serve basis? Or is this the default behaviour?
The official MySQL documentation doesn't mention anything about the blocked thread order for threads of the same lock type (ie multiple threads attempting a WRITE LOCK). It only mentions that a WRITER will jump to the front of the waiting queue if READERS are waiting.
© Stack Overflow or respective owner