On Feb 1, 2008, at 4:07 PM, Dave Glowacki wrote:

I seem to have turned up a race condition in the ThreadPool class.

Here's a patch for an aggressively locked version of the ThreadPool.Poolable class which works under JRockit.

I removed the 'synchronized' from all the Poolable methods and instead locked the individual data objects so that the lock order could be guaranteed.

I'm not sure it's necessary to lock the 'shuttingDown' boolean as I've done in the patch -- the worst thing that could happen is that one or two threads runs a little longer than necessary.

Please let me know if you have any questions or comments (and thanks for the XML-RPC library -- you might be happy to know that it's running on machines at the South Pole!)

Here's the patch:

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to