Details
-
Improvement
-
Resolution: Unresolved
-
Minor - P4
-
None
-
2.2.2
-
Major Change
Description
I migrated from 1.9 to 2.2 and reading the documentation I was surprised to discover that is not possible to upsert during a bulk operation anymore, since operations don't allow options.
bulkOps.Add(new UpdateOneModel<BsonDocument>(filter, update));
|
collection.BulkWrite(bulkOps);
|
Should be
options.isUpsert = true;
|
bulkOps.Add(new UpdateOneModel<BsonDocument>(filter, update, options));
|
collection.BulkWrite(bulkOps);
|
Is this work in progress, intended, or I'm missing something? Thank you.