Announce: memcache support

Brad Fitzpatrick brad at
Wed Jan 17 23:09:38 UTC 2007


As of mogilefs svn 717 and 718, mogilefs can now optionally use memcache
to avoid the database when doing get_paths requests.

See doc/memcache-support.txt for details, which currently says:


An oft-requested feature, now implemented, is memcached support within
the tracker, in particular to speed up get_paths requests and reduce
load on the database.

After years of saying it's stupid, I finally implemented it, but I
still maintain it's (usually) stupid.

Really, you should cache get_paths requests in your application,
avoiding an extra round-trip to the trackers that could be avoided on
a cache hit.

That is, you should do:

1)   app <-> memcache

Rather than:

2)   app <-> tracker <-> memcache

Although, if 1) is too hard, it's true that 2) is cheaper than 3):

3)   app <-> tracker <-> db.

So now you have lots of options!

To use memcached support on get_paths requests, telnet to one of your
trackers and do:

    set_server_setting key=memcache_servers&value=

(where value is a comman-separated list, if you have multiple)

And then all future get_paths requests with noverify=1 (which now
doubles as the "memcached is okay" flag) will use memcache.

All this may change in the future, but the instructions given here
will remain compatible if things do change.




More information about the mogilefs mailing list