[concurrency-interest] Quest for the optimal queue

√iktor Ҡlang viktor.klang at gmail.com
Fri May 11 15:20:00 EDT 2012


On Fri, May 11, 2012 at 7:55 PM, Nathan Reynolds <nathan.reynolds at oracle.com
> wrote:

>  I've heard of disruptor and they have some results comparing it against
> ArrayBlockingQueue.
> http://code.google.com/p/disruptor/wiki/PerformanceResults  I don't know
> how it would compare against ConcurrentLinkedQueue.
>

Their ring buffer is a no-go since it violates the unbounded constraint.
(and also the preallocation thing will be a big no no since I need to have
million of these).

Since I do not need any other operations than the ones I listed, I was sort
of thinking there might be some optimization opportunities that might be
applicable to improve upon the latency of the CLQ.

Cheers,
√


>
>
>  Nathan Reynolds<http://psr.us.oracle.com/wiki/index.php/User:Nathan_Reynolds>| Consulting Member of Technical Staff |
> 602.333.9091
> Oracle PSR Engineering <http://psr.us.oracle.com/> | Server Technology
>
> On 5/11/2012 8:00 AM, √iktor Ҡlang wrote:
>
> Hey guys,
>
>  I'd like to explore alternatives to ConcurrentLinkedQueue, especially to
> get a bit lower latency and perhaps even lower mem usage.
>
>  Behavior:
> No locks
> Unbounded
> Single consumer
> Multiple producers
>
>  Operations:
>
>  dequeue
> enqueue
> numberOfMessages // Would be nice to have as a constant, can be linear or
> simply not supported, doesn't really matter
> hasMessages // Just a Boolean if there's anything in there at all, only
> needs to return true if something has been put in that hasn't been pulled
> out yet
>
>  Is there anything out there which is better than CLQ?
>
>  Cheers,
>>
>  --
> Viktor Klang
>
> Akka Tech Lead
> Typesafe <http://www.typesafe.com/> - The software stack for applications
> that scale
>
> Twitter: @viktorklang
>
>
>
> _______________________________________________
> Concurrency-interest mailing listConcurrency-interest at cs.oswego.eduhttp://cs.oswego.edu/mailman/listinfo/concurrency-interest
>
>


-- 
Viktor Klang

Akka Tech Lead
Typesafe <http://www.typesafe.com/> - The software stack for applications
that scale

Twitter: @viktorklang
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://cs.oswego.edu/pipermail/concurrency-interest/attachments/20120511/c8984bab/attachment.html>


More information about the Concurrency-interest mailing list