I have uploaded Q4M 0.9.1 to the prerelease directory on q4m.31tools.com.
http://q4m.31tools.com/dist/pre/
The release fixes a deadlock of more than three threads, involving
access to more than two tables. Please try using the prerelease
version, if you have multiple Q4M tables and are facing deadlocks.
A detailed explanation of the problem is in the svn log, as is
attached to the end of this e-mail.
The new release (0.9.1) has passed our test suite and building
process, but I have placed it in the prerelease directory just in case
I have broken something else while fixing the problem.
And thank you to the users of Q4M for reporting the problem with
sending stacktraces. Without them I have been unable to find and fix
this kind of bug.
------------------------------------------------------------------------
r281 | kazuho | 2010-01-19 22:54:04 +0900 (Tue, 19 1 2010) | 16 lines
0.9.1 release to hopefully provide fix to users having deadlock problem
the problem in detail:
- unlock_reader()
owns rwlock (write lock) and mutex (rwlock and mutex are per-table
locks), waiting for writer_start to respond
- ha_queue::writer_start() -- calling --> wake_listeners()
owns mutex (of another table), trying to lock listener_mutex (a global lock)
- ha_queue::_queue_wait_core() -- calling --> queue_share_t::lock_reader()
owns listener_mutex, trying to lock rwlock (read lock)
the fix: use timedlock in writer_start() and retry laterwards
--
Kazuho Oku