nInserted incremented despite error

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Done
    • Priority: Major - P3
    • None
    • Affects Version/s: 0.94.0
    • Component/s: Bulk API, libmongoc
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Starting at this commit:

      https://github.com/mongodb/mongo-c-driver/commit/48a859952204acd3ad9d057e2b36ecd01218c529#diff-37eb77aadf1acdb5086324d8a2056e7eR308

      the nInserted number reported for a batch OP_INSERT is incremented, even for documents the server rejects. Observed in mongoc_bulk_operation_insert, may be the same for all insert APIs.

            Assignee:
            A. Jesse Jiryu Davis
            Reporter:
            A. Jesse Jiryu Davis
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: