Re: Double null check sync problem fix.

From: Doug Lea (
Date: Sun Dec 17 2000 - 14:18:59 EST

> For the two cases below, firstly teh _queue is lazy as many
> instances of ThreadPool specialize getJob to avoid having a queue
> of jobs at all (eg ThreadedServer has all it's threads sitting in
> accept waiting for a connection).

Consider instead having the type of queue to use (if any) as a
constructor argument. The _queue could in that case even be declared
as "final", eliminating further synch/visibility worries.


This archive was generated by hypermail 2b29 : Thu Oct 13 2005 - 07:00:29 EDT