From: hemant Date: 2006-10-24T02:25:38+09:00 Subject: Re: Fast portable storage for queues On 10/23/06, Francis Cianfrocca wrote: > On 10/23/06, Patrick Hurley wrote: > > > > Hey Chris, > > > > Thanks for the continued interest and work on stompserver, I am on my > > way home and will be helping out soon. I will give a big thumbs up to > > using the file system. It is actually where I was planning on going, > > but used Madeleine because it was faster to get started. > > > > Another approach that I am planning on investigating is on using mmap > > (based on a discussion and idea I while talking with Daniel Berger at > > RubyConf) to provide a circular queue space -- this should be very > > efficient and simple enough to implement -- until the allocated queue > > is full. Then special logic and handling or an expensive resize would > > be required. > > > > pth > > > > > > mmap and circular space: I have an implementation of that. It's fast as > bloody hell, but it's also (unfortunately) a compiled Ruby extension. Let me > know if you want to play with it when you get home. If you like it, maybe > you can convert it to pure Ruby without losing too much performance. One of > the keys to performance is fixed-length record-buffers, which means there's > no record-table. All lookups are O(1). > > Send it across Franics, I would be delighted to check it. -- There was only one Road; that it was like a great river: its springs were at every doorstep, and every path was its tributary.