[concurrency-interest] Is LinkedBlockingQueue.isEmpty() thread safe?

Kasper Nielsen kasper at kav.dk
Thu Apr 19 18:07:39 EDT 2007

Szabolcs Ferenczi wrote:
> LBQ is meant to be a shared data structure used by concurrent threads.
> It has a method: isEmpty() with the following documentation:
> "Returns true if this collection contains no elements."
> Is it thread safe?
Yes it is thread safe. And what exactly makes you wonder if it isn't?

- Kasper

More information about the Concurrency-interest mailing list