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

Investigate fine-grained locking in CheckpointManager

    XMLWordPrintable

Details

    Description

      Frontend operations that need to queue an item into the Checkpoint must acquire the CM::queueLock.
      If a background task holds the same lock then any frontend thread (touching the same vbucket) would block.

      That's the legacy problem that this MB addresses.

      Now, code in the Checkpoint area has changed considerably even if we consider just the latest CB versions (eg 6.5, 6.6, 7.0).
      In particular, in the recent changes in MB-46827, MB-47386, MB-48038 we have minimized the work that some background operations (eg, CheckpointRemoval) do under CM::queueLock.
      So we need a re-assessment of the current state before proceeding with any change.

      Attachments

        1. dcp.png
          dcp.png
          354 kB
        2. trace_ckpt-rem.png
          trace_ckpt-rem.png
          409 kB
        3. trace_expel_dcp.png
          trace_expel_dcp.png
          180 kB
        4. trace_heavy_expel.png
          trace_heavy_expel.png
          527 kB
        5. trace_item-expel.png
          trace_item-expel.png
          430 kB

        Issue Links

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

          Activity

            People

              paolo.cocchi Paolo Cocchi
              paolo.cocchi Paolo Cocchi
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes

                  PagerDuty