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

Query reason code returning 5000

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 7.1.0
    • 7.1.0
    • query
    • Enterprise Edition 7.1.0 build 2071
    • Untriaged
    • 1
    • Unknown

    Description

      Hi,

      while implementing the improved query error handling for the SDKs, I noticed a discrepancy between the asserted codes and the actual returned ones.

      Based on discussions we expected:

      • Error Code 12009
      • Reason Code 12033: #9 CasMismatch
      • Reason Code 17014: #101 DocumentNotFound
      • Reason Code 17012: #105 DocumentExists

      But when inserting two docs instead of 17012 I get 5000:

      insert into a(key,value) values ('k1',{});
      insert into a(key,value) values ('k1',{});
      

      [
        {
          "code": 12009,
          "msg": "DML Error, possible causes include concurrent modification. Failed to perform INSERT on key k1 - cause: Key k1 - cause: unable to complete action after 1 attempts: key exists",
          "reason": {
            "caller": "couchbase:1949",
            "code": 5000,
            "icause": "unable to complete action after 1 attempts: key exists",
            "key": "Internal Error",
            "message": "Key k1"
          }
        }
      ]
      

      Donald Haggart mentioned that this could be due to a recent (unrelated) change made, so raising this ticket to track.

      Attachments

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

        Activity

          People

            daschl Michael Nitschinger
            daschl Michael Nitschinger
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty