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

[CDC] KV using wrong time unit in time callbacks

    XMLWordPrintable

Details

    Description

      Steps to repro:

      1. Create a single cluster
      2. Create a magma bucket with (history_retention_collection_default=true,bucket_history_retention_seconds=86400,bucket_history_retention_bytes=96636764160) (Vbucket count = 1)
      3. Create one collection(total collections including default are two)
      4. Create 1000 documents(doc size = 1024 bytes)
      5. Update 1000 docs with expiry(set to 15 seconds)
      6. Sleep for 15 seconds for docs to expire
      7. Set expiry pagers time to 10 seconds
      8. Wait until exp_pager_stime for kv_purger to kickoff
      9. wait for 300 seconds for KV purger to scan expired docs and add tombstones
      10. Until this point all the stats shows correct value

         vb_0:high_seqno:                          3001
         vb_0:history_start_seqno:                 1
        

      11. ReSet expiry pagers time to 10000000000 seconds
      12. Recreate 1000 docs with expiry set to 13 seconds
      13. Sleep for 13 seconds for docs to expire
      14. Set expiry pagers time to 10 seconds
      15. # Wait until exp_pager_stime for kv_purger to kickoff
      16. wait for 300 seconds for KV purger to scan expired docs and add tombstones
      17. Stats now also shows correct value

        -bash-4.2# /opt/couchbase/bin/cbstats localhost:11210 -u Administrator -p password -b default vbucket-details 0 | grep -e history -e high_seqno
         vb_0:high_seqno:                          5001
         vb_0:history_start_seqno:                 1
        

      18. Repeat steps 11 to 15(this time expiry is set to 12 seconds)
      19. History start seq number gets set to new value 5002

        -bash-4.2# /opt/couchbase/bin/cbstats localhost:11210 -u Administrator -p password -b default vbucket-details 0 | grep -e history -e high_seqn
         vb_0:high_seqno:                          6001
         vb_0:history_start_seqno:                 5002
        -bash-4.2#
        -bash-4.2#
        -bash-4.2# /opt/couchbase/bin/cbstats localhost:11210 -u Administrator -p password -b default vbucket-details 0 | grep -e history -e high_seqn
         vb_0:high_seqno:                          7001
         vb_0:history_start_seqno:                 5002
        

      QE-TEST:

      git fetch https://review.couchbase.org/TAF refs/changes/62/186462/2 && git checkout -b change-186462 FETCH_HEAD
      guides/gradlew --refresh-dependencies testrunner -P jython=/opt/jython/bin/jython -P 'args=-i /tmp/temp_vol_3.ini -p bucket_storage=magma,bucket_ram_quota=256,init_loading=False,bucket_eviction_policy=fullEviction,rerun=False -t storage.magma.cdc_steady_state.SteadyStateTests.test_history_retention_for_n_expire_iterations,nodes_init=1,skip_cleanup=True,num_items=1000,doc_size=1024,batch_size=1000,sdk_timeout=60,log_level=info,infra_log_level=info,key_size=22,num_collections=2,ops_rate=20000,key_type=RandomKey,vbuckets=1,replicas=2,test_itr=10,bucket_history_retention_seconds=86400,bucket_history_retention_bytes=96636764160,standard_buckets=1,magma_buckets=1,num_scopes=1 -m rest'
      

      Attachments

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

        Activity

          People

            ankush.sharma Ankush Sharma
            ankush.sharma Ankush Sharma
            Votes:
            0 Vote for this issue
            Watchers:
            8 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                PagerDuty