Uploaded image for project: 'Couchbase Gateway'
  1. Couchbase Gateway
  2. CBG-3879

[3.1.7 Backport] Recovery from cas mismatch on metadata documents when using xattrConfig

    XMLWordPrintable

Details

    • Improvement
    • Resolution: Fixed
    • Major
    • 3.1.7
    • 3.1.4
    • SyncGateway
    • Security Level: Public
    • None
    • CBG Sprint 150
    • 1

    Description

      When using xattr bootstrap persistent, we write document cas to the metadata.  This we originally intended to detect cases where the registry has been modified or copied into the cluster by an actor other than the local Sync Gateway cluster (i.e. to prevent injection of external configs with unsupported properties).

      Reads and writes are performed using this cfgCas value, and not the document cas.  However, we don't have any handling to recover from situations where there's a mismatch between the actual document cas and the value stored in the metadata. When this happens, the registry and database become unwritable (as the invalid cfgCas is used as cas when writing the documents), and will always return a conflict on update.

      Need to review the strategy for preventing prohibited direct updates to the document while still providing a recovery path. 

      Attachments

        Activity

          People

            adamf Adam Fraser
            ben.brooks Ben Brooks
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              PagerDuty