using Tugela Cache?
Jehiah Czebotar
jehiah at gmail.com
Mon Aug 20 18:28:01 UTC 2007
thanks for answering questions i wasn't asking; i already know
perfectly well what constraints it adds to the system i'm designing;
but thats a problem for me to solve, not you
On 8/20/07, Paul Querna <chip at corelands.com> wrote:
> Jehiah Czebotar wrote:
> > Is anyone on this list actively using Tugela Cache?
> >
> > (if you are not familiar with it; it follows the memcached api, but
> > instead of storing in memory it stores data in a berkeley db file;
> > this means you can use all the normal memcached clients)
> >
> > http://meta.wikimedia.org/wiki/Tugela_Cache
> >
>
> But uh. It introduces blocking IO into a event based IO program.
> BerkeleyDB does NOT have an AIO API -- so you are stuck blocking.
>
> The 'right' way is to have a set of BDB worker threads which do all the
> BDB IO in their blocking way, but keeping the event thread handling events.
>
> It would then pass off all the requests to a fifo queue, BDB worker
> threads would consume from that.
>
> When a worker thread has a completed request, it pushes the data onto an
> event, which the event thread can then write out to clients.
>
> If a pluggable-storage project ever happened, this wouldn't be too hard
> to write....
>
> -Paul
>
>
More information about the memcached
mailing list