On Feb 6, 2008, at 10:26 PM, josh rotenberg wrote: > grr, this cold is making me dumber than usual. the link: > > http://code.google.com/p/modmemcachecache/ Shame I did not discover your code before ! Mine(1) looks fairly very similar - Except I sort of started with apr_brigade_pflatten() as well - but then removed it to see if that would let me cut off things which are too large earlier - and then got into the mess of re-allocing and what not. But that was propably the wrong path. Let me see if I can merge things a bit. Dw 1: http://www.webweaving.org/tmp/mod_memcached-hack.c > > > On Feb 6, 2008 1:25 PM, josh rotenberg > wrote: >> if it helps at all, here was my attempt at a working >> mod_memcached_cache. i've been meaning to look at it again and do >> some >> cleanup/testing/benchmarking/etc, haven't had the chance though. >> >> >> >> >> On Feb 5, 2008 11:17 AM, Dirk-Willem van Gulik >> wrote: >>> >>> >>> On Feb 5, 2008, at 7:58 PM, Colm MacCarthaigh wrote: >>> >>>> On Tue, Feb 05, 2008 at 01:49:43PM -0500, Garrett Rooney wrote: >>>>> On Feb 5, 2008 1:45 PM, Dirk-Willem van Gulik >>>>> wrote: >>>>>> Caching experts -- why do memcache and diskcache have seemingly >>>>>> quite >>>>>> different caching strategies when it comes to storing the >>>>>> headers ? >>>>>> E.g. the cache_object_t * is populated with the status/date/etc >>>>>> data >>>>>> in memcache - but not in disk-cache. Is this work in progress or >>>>>> subtle design ? >>>>>> >>>>>> I am trying to understand (got a working >>>>>> mod_memcached_cache.c* -- >>>>>> and cannot quite get the right VARY behaviour). >>>>> >>>>> If I had to guess I'd say it's because people have actually been >>>>> working on disk cache, while mem cache has been largely ignored >>>>> for a >>>>> while. >>>> >>>> Definitely! I remember the original patches tried to create some >>>> nice >>>> abstractions so that more logic would move into mod_cache propery >>>> than >>>> in mod_*_cache, but there turned out to be so many corner cases >>>> within >>>> mod_disk_cache itself - and noone seems to /use/ mod_mem_cache - >>>> that >>>> that fell by the wayside :/ >>> >>> Thanks ! That is useful info -- so for now I'll focus on >>> mod_disk_cache -- and once I got that mapped to mod_memcached -- >>> will >>> then see if we can abstract that into a cleaner mod_memcache. But >>> first priority is getting it clean-ish/same-ish relative to the ssl >>> use of memcached (my usecase is OpenID -- which is 'heavy' on both). >>> >>> Dw >>> >>