[SPY-124] append/incr/decr/add/replace should not require CAS value to be passed Created: 21/Jun/12 Updated: 04/Jun/13 Resolved: 04/Jun/13
|Project:||Spymemcached Java Client|
|Reporter:||Perry Krug||Assignee:||Michael Nitschinger|
|Remaining Estimate:||Not Specified|
|Time Spent:||Not Specified|
|Original Estimate:||Not Specified|
In the current implementation, there is no method for a non-CAS version of the append/prepend/incr/decr/add/replace operations. As per the memcached protocol, these operations do not require (but may be used with) a CAS id and requiring one greatly reduces the performance available by requiring a gets prior to the operation.
|Comment by Raghavan Srinivas (Inactive) [ 22/Aug/12 ]|
The incr, decr, add and replace do have calls that do not require CAS Id. For the append and prepend methods
you could do something like this
c.prepend(0, "prepend-key", "value");
which would not require a CAS to be supplied/fetched. Will this suffice for now?
My suggestion would be to close this issue and open a separate issue for just append and prepend if it's still deemed a bug.
|Comment by Michael Nitschinger [ 21/Dec/12 ]|
|Comment by Perry Krug [ 21/Dec/12 ]|
|This will need a docs update as well...|
|Comment by Perry Krug [ 06/Feb/13 ]|
|Michael, just to add here, I think it would be sufficient to document this rather than changing the API itself. Documenting that you can (and should!) pass 0 for the CAS value when using these operations.|