Not really. If could synchronize it externally using some kind of a
distributed lock server.
Or you could "wrap" those 2 keys into an object of some sort and write out
the object. This way it's atomic.

This thread may help.

http://groups.google.com/group/memcached/browse_thread/thread/b618703f38343bd5/dd633930dca50ecf?hl=en&ie=UTF-8&q=lock+server+memcached&pli=1

On Tue, Nov 24, 2009 at 11:11 AM, juanbackson <[email protected]> wrote:

> Hi,
>
> I have two distributed clients that need to write stuff to memcached,
> but each write will involve two records.   These two records must be
> sync.  So, they must be changed together.
>
> Is there anyway that I can lock on those two records and write them,
> so there won't be issue with two clients writing at the same time?
>
> thanks,
> jb
>



-- 
--Boris

Reply via email to