Using dupsAllowed=false when inserting into a secondary unique index results in inserting + removing on a "prefix" document to serialize access to enforce unique constraints.
However the preceding comment states the expectation that only primaries are executing that code path.
This results in unnecessary writes to these prefix documents. Moreover, these writes can result in out of order update chains as secondaries can process oplog entries out of order.
- depends on
-
SERVER-61459 ShardingCatalogManager::assignKeyRangeToZone() reads stale version of CollectionType while running locally on config server primary
- Closed
- is duplicated by
-
SERVER-60716 Remove out of order writes on unique, non _id indexes
- Closed
- is related to
-
SERVER-60037 Enable the ordered timestamp assertion in MongoDB
- Closed
- related to
-
SERVER-61458 Calling RSLocalClient::queryOnce(kMajorityReadConcern) causes subsequent local writes in same OperationContext to also read stale data
- Closed
-
SERVER-61499 Complete TODO listed in SERVER-60716
- Closed
-
WT-7853 Validate the update chain before we attempt to insert it into the history store
- Closed