Uploaded image for project: 'Couchbase Server'
  1. Couchbase Server
  2. MB-34606

[Durability] Doc TTL started at sync_write prepare, not at sync_write commit

    XMLWordPrintable

Details

    Description

      Build: 6.5.0-3499

      Scenario:

      1. Create 2 node cluster
      2. Default Couchbase bucket with replicas=1
      3. Stop Memcached on node-2 (kill -STOP pid)
      4. Load 50 docs such that it is inserted into node-1's active Vbucket with doc_ttl=20 and sdk_timeout=60
      5. Sleep for 30 seconds
      6. Resume Memcached on node-2 (kill -CONT pid)
      7. Now all doc_ops succeeds
      8. Set flush_param exp_pager_stime = 1 on all nodes
      9. Read all the inserted docs

      Observation:

      8 docs are missing during the read operation, which means the doc's TTL has started (at step #4) before the sync_write commit succeeded (after step #6). This is because we are using 8 threads to insert docs into the server using Java SDK 2.0.0-alpha2.

      Note: If the same test case is run with doc_ttl=50, the test passes.

      Following doc_keys are missing during the read operation:

      [u'test_ttl_docs-51', u'test_ttl_docs-73', u'test_ttl_docs-84', u'test_ttl_docs-30', u'test_ttl_docs-41', u'test_ttl_docs-63', u'test_ttl_docs-6', u'test_ttl_docs-17']

      TAF test to reproduce this issue:

      /usr/bin/jython  -J-cp jars/sdk3.0/*:jars/* /Users/ashwin/gitRepos/couchbaselabs/TAF/testrunner.py -i node.ini -m rest -tepengine.expiry_maxttl.ExpiryMaxTTL.test_maxttl_with_timeout,nodes_init=2,replicas=1,num_items=50,doc_ttl=30,sdk_timeout=60,durability=MAJORITY

       

      Attachments

        1. java_sdk_timeout.pcapng
          16 kB
        2. JavaSDK.log
          2.07 MB
        3. test_run.log
          15 kB

        Issue Links

          Activity

            People

              ashwin.govindarajulu Ashwin Govindarajulu
              ashwin.govindarajulu Ashwin Govindarajulu
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                PagerDuty