Uploaded image for project: 'Spymemcached Java Client'
  1. Spymemcached Java Client
  2. SPY-124

append/incr/decr/add/replace should not require CAS value to be passed

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.9.0
    • Component/s: library
    • Security Level: Public
    • Labels:
      None
    • Sprint:
      Sprint 1 - CW 19 & 20

      Description

      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.

      Perry

        Issue Links

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

          Hide
          rags Raghavan Srinivas (Inactive) added a comment -

          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.

          Show
          rags Raghavan Srinivas (Inactive) added a comment - 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.
          Show
          daschl Michael Nitschinger added a comment - http://review.couchbase.org/#/c/23486/
          Hide
          perry Perry Krug added a comment -

          This will need a docs update as well...

          Show
          perry Perry Krug added a comment - This will need a docs update as well...
          Hide
          perry Perry Krug added a comment -

          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.

          Show
          perry Perry Krug added a comment - 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.

            People

            • Assignee:
              daschl Michael Nitschinger
              Reporter:
              perry Perry Krug
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Agile

                  Gerrit Reviews

                  There are no open Gerrit changes