[concurrency-interest] leaders/followers pattern

Doug Lea dl at cs.oswego.edu
Thu Jun 9 07:13:05 EDT 2005

Nearly all java.util.concurrent queues, locks, etc., are designed
to by default deliver high throughput -- you have to specifically
disable this using fairness settings.

High throughput almost always means low context switching.
The techniques uesed here are related to Leaders/followers
(which is a form of directed handoff), but usually perform
even better.

There are some kinds of IO-related applications where you
may be able to do better still. It's too bad that JSR203
is still on hold (current plans seem to be to postpone
until J2SE7) -- this probably will include an async IO
framework. Until then, if you are doing this sort of thing,
you might consider using Coconut AIO, that is built on top
of java.util.concurrent


More information about the Concurrency-interest mailing list