mongo-go-driver icon indicating copy to clipboard operation
mongo-go-driver copied to clipboard

GODRIVER-2388 Improved Bulk Write API.

Open qingyang-hu opened this issue 1 year ago • 1 comments

GODRIVER-2388

Summary

Improved Bulk Write API.

Background & Motivation

qingyang-hu avatar Sep 11 '24 22:09 qingyang-hu

API Change Report

./mongo

compatible changes

(*Client).BulkWrite: added ClientBulkWriteException: added ClientBulkWriteResult: added ClientDeleteManyModel: added ClientDeleteOneModel: added ClientDeleteResult: added ClientInsertOneModel: added ClientInsertResult: added ClientReplaceOneModel: added ClientUpdateManyModel: added ClientUpdateOneModel: added ClientUpdateResult: added ClientWriteModels: added

./mongo/options

compatible changes

ClientBulkWrite: added ClientBulkWriteOptions: added MergeClientBulkWriteOptions: added

./x/mongo/driver

incompatible changes

(*Batches).AdvanceBatch: removed (*Batches).ClearBatch: removed (*Batches).Valid: removed Batches.Current: removed ##NewCursorResponse: changed from func(ResponseInfo) (CursorResponse, error) to func(./x/bsonx/bsoncore.Document, ResponseInfo) (CursorResponse, error) Operation.Batches: changed from *Batches to interface{AdvanceBatches(n int); AppendBatchArray(dst []byte, maxCount int, maxDocSize int, totalSize int) (int, []byte, error); AppendBatchSequence(dst []byte, maxCount int, maxDocSize int, totalSize int) (int, []byte, error); IsOrdered() *bool; Size() int} ##Operation.ProcessResponseFn: changed from func(ResponseInfo) error to func(context.Context, ./x/bsonx/bsoncore.Document, ResponseInfo) error ResponseInfo.ServerResponse: removed

compatible changes

(*Batches).AdvanceBatches: added (*Batches).AppendBatchArray: added (*Batches).AppendBatchSequence: added (*Batches).IsOrdered: added (*Batches).Size: added ExtractCursorDocument: added ResponseInfo.Error: added

./x/mongo/driver/session

incompatible changes

Client.RetryWrite: removed

./x/mongo/driver/wiremessage

incompatible changes

ReadCompressedCompressedMessage: removed

compatible changes

DocumentSequenceToArray: added