In your example below you don't use the replace command, but the set command..
Cheers, Trond On Mon, Dec 28, 2009 at 7:00 AM, schettino72 <[email protected]> wrote: > Hi, > > The protocol definition (http://code.sixapart.com/svn/memcached/trunk/ > server/doc/protocol.txt) says that: > > "NOT_STORED\r\n" to indicate the data was not stored, but not > because of an error. This normally means that either that the > condition for an "add" or a "replace" command wasn't met, or that the > item is in a delete queue (see the "delete" command below). > > So as far as I could understand if i issue a "replace" command for a > non-existen key I should get a "NOT_STORED" but I always get a STORED > response for replace... > > <30 set abc 0 10 1 # replace command > >30 STORED > <30 get abc # not stored > >30 END > <30 set abc 0 10 1 # set command > >30 STORED > <30 get abc # stored > >30 sending key abc > >30 END > > Is this a bug or I missing something? > > tested on memcached 1.4.4 (ubuntu) and memcached 1.2.2 (debian lenny) > > regards, > Eduardo > -- Trond Norbye
