# Memcached vs regex fragment expiry

**URL:** <https://www.ruby-forum.com/t/memcached-vs-regex-fragment-expiry/50415>\
**Category:** Rails\
**Created:** [December 16, 2005, 2:41am UTC](https://www.ruby-forum.com/t/memcached-vs-regex-fragment-expiry/50415 "2005-12-16T02:41:30Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jamie\_Wilson](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/9fc348/32.png) [@Jamie\_Wilson](https://www.ruby-forum.com/u/Jamie_Wilson)\
**Post date:** [December 16, 2005, 2:41am UTC](https://www.ruby-forum.com/t/memcached-vs-regex-fragment-expiry/50415/1 "2005-12-16T02:41:30Z")

</div>

Hi,

I thought i’d give memcached a try. Installed it all, made the change  
in environment.rb and it all seems ok. I can telnet to memcached  
process and manually retrieve the data being cached.

However, when I try to expire a fragment using a regex, eg:

```
expire_fragment(%r{forums/recent/.*})

```

it throws an error:

```
undefined method `delete_if' for #<MemCache:0x2289968>

```

I’m assuming i’m doing something stupid… Should the above work?  
Have I missed out a vital step?

Oh well, back to the FileStore for now. ☹

…j
