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

XATTRs don't persist after document body replace / upsert operation

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 5.0.0
    • 5.0.0
    • couchbase-bucket
    • Untriaged
    • Centos 64-bit
    • Unknown

    Description

      If an Upsert/Replace document operation is done against an existing document with XATTRs, the XATTRs are lost.

      For example:

      const string key = "xattrs_demo";
      const string createBy = "jack";
       
      _bucket.Remove(key);
      _bucket.Insert(key, new {name = "mike"});
       
      _bucket.MutateIn<dynamic>(key)
          .Upsert("_data.created_by", createBy, SubdocFlags.CreatePath | SubdocFlags.AttributePath)
          .Execute();
       
      _bucket.Replace(key, new {name = "michael"});
       
      _bucket.LookupIn<dynamic>(key)
          .Get("_data.created_by", SubdocFlags.AttributePath)
          .Execute();
      

      The response code is 0x00c0 with message: Subdoc: Path not does not exist. I've attached a pcap file with my requests.

      Attachments

        Issue Links

          For Gerrit Dashboard: MB-22432
          # Subject Branch Project Status CR V

          Activity

            People

              mike.goldsmith Michael Goldsmith
              mike.goldsmith Michael Goldsmith
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes

                  PagerDuty