Abhilash
Deleting cache objects by group
October 15, 2010 06:10PM
Hey,

Is there a way I can delete the cache objects by group?
I am using net.spy.memcached.MemcachedClient as my Java client. But it
offers a functionality to delete cache by key.

I am looking for something where I can group my keys and delete the
group whenever I need to delete all of them.

Thanks
Abhilash
Boris Partensky
Re: Deleting cache objects by group
October 15, 2010 06:20PM
You can have your group identifier as a part of key. Whenever you want
to delete the group, you change your "current" identifier (increment
or whatever), so all subsequent get() calls for that group will miss.
It's a classic memcached namespace problem, look at the link below.

http://code.google.com/p/memcached/wiki/FAQ#Deleting_by_Namespace

On Fri, Oct 15, 2010 at 10:52 AM, Abhilash <[email protected]> wrote:
> Hey,
>
> Is there a way I can delete the cache objects by group?
> I am using net.spy.memcached.MemcachedClient as my Java client. But it
> offers a functionality to delete cache by key.
>
> I am looking for something where I can group my keys and delete the
> group whenever I need to delete all of them.
>
> Thanks
> Abhilash
Sorry, only registered users may post in this forum.

Click here to login