If the parent key is always going to be related to the child key, you can
already always get this data via multiget.

If you use a client which allows storage/fetch by 'master' key, you can
force both keys to always be on the same server. Then you always use a
multiget to fetch them back, which does one roundtrip.

libmemcached and Cache::Memcached support the fetch-by-master stuff.

-Dormando

On Fri, 31 Oct 2008, Aaron Stone wrote:

>
> That sounds like a great solution except for the doubled request
> overhead... *thinks out loud for benefit of mailing list archives*
> ...batched requests, so you GETQ the parent and GET the child and then
> you have everything you need to know about whether the child data is
> valid.
>
> Aaron
>
>
> On Wed, Sep 24, 2008 at 7:11 AM, Stephen Johnston
> <[EMAIL PROTECTED]> wrote:
> > We do a similar sort of thing, but instead of using a "namespace" we have
> > keys that have a parent key. We check the "parent" key before checking the
> > child. If the parent is marked as invalidated or is non-existent then we
> > treat that as the state of the child. If the parent exists, then we check
> > the state of the child like usual.
> >
> > -Stephen
>

Reply via email to