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

ACID Transactions trigger eventing function before commit

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • Major
    • Morpheus
    • 6.5.0
    • eventing
    • CB 6.5.0 on RHEL 7.7
    • Untriaged
    • Centos 64-bit
    • 1
    • Unknown

    Description

      When inserting documents in CB Server as a part of a transaction blank documents are created on the server. See MB-39941 for details. 

      Eventing functions are able to 'see' these empty documents and are triggered twice. Once for the empty docs before commit and again after the docs are committed. My eventing function copies all docs from a source bucket to target bucket. As seen below, the docs are visible in Target bucket even before transaction is committed. 

       

      select *, meta().id from target use keys ["doc::1","doc::200","doc::1500"];
      [{"id":"doc::1","target":{}},{"id":"doc::200","target":{}}]
      

       

      Attachments

        Issue Links

          Activity

            People

              ankit.prabhu Ankit Prabhu
              jeelan.poola Jeelan Poola
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:

                PagerDuty