Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 0.5
    • Fix Version/s: 0.8.0
    • Component/s: library
    • Security Level: Public
    • Labels:
      None

      Description

      This was originally observed with an older version, and in trying to reproduce it the latest change seems to show incr/decr is further broken. Still, this should be an easy test to add since it's been verified to fail.

      from pymembase.membaseclient import VBucketAwareMembaseClient
      client_one = VBucketAwareMembaseClient('http://host/pools/default','default','')
      client_two = VBucketAwareMembaseClient('http://host/pools/default','default','')

      1. Client one sets a numeric key
        client_one.set('jacob',0,0,'20')
        client_one.get('jacob')
      1. Client two tries to increment this numeric key
        client_two.incr('jacob')
      2. This returns (0, cas) - it should be 21!
      3. Client two can keep incrementing this weird key
        client_two.incr('jacob')
      4. Returns (1, cas)
      1. However - if client two gets the key...
        client_two.get('jacob')
        client_two.incr('jacob')
      2. (21, cas)
      3. !!!

      p.s.: want to thank oliland from IRC on reporting this

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

        Activity

        Hide
        ingenthr Matt Ingenthron added a comment -

        Could not reproduce this with another client.

        Show
        ingenthr Matt Ingenthron added a comment - Could not reproduce this with another client.
        Hide
        oliland Oli Kingshott added a comment -

        Analyzing the binary protocol in Wireshark shows that the VBucketID is not set for the second client when it calls incr() without doing a get() first. Will try and see how this relates to the source code.

        Show
        oliland Oli Kingshott added a comment - Analyzing the binary protocol in Wireshark shows that the VBucketID is not set for the second client when it calls incr() without doing a get() first. Will try and see how this relates to the source code.
        Hide
        BigBlueHat Benjamin Young added a comment -

        I've added the above code (nearly) as a test case here:
        https://github.com/BigBlueHat/couchbase-python-client/commit/e3e31cdf7950abb35012fa06195ffea4c6710019

        I'd love to get a few others to test it. It was failing, now it isn't. I've only tested it against 1.8.0 thus far.

        Show
        BigBlueHat Benjamin Young added a comment - I've added the above code (nearly) as a test case here: https://github.com/BigBlueHat/couchbase-python-client/commit/e3e31cdf7950abb35012fa06195ffea4c6710019 I'd love to get a few others to test it. It was failing, now it isn't. I've only tested it against 1.8.0 thus far.
        Hide
        ingenthr Matt Ingenthron added a comment -

        @benjamin to run this test again with current codebase and current server, then close if it can't be duplicated.

        Show
        ingenthr Matt Ingenthron added a comment - @benjamin to run this test again with current codebase and current server, then close if it can't be duplicated.
        Show
        BigBlueHat Benjamin Young added a comment - http://review.couchbase.org/#/c/20369/

          People

          • Assignee:
            BigBlueHat Benjamin Young
            Reporter:
            ingenthr Matt Ingenthron
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Gerrit Reviews

              There are no open Gerrit changes