-
Type: Bug
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: None
-
Component/s: Sharding
-
Labels:
-
Fully Compatible
-
ALL
-
Sharding 2020-11-02
-
13
This variant inside _logOpsInner was added to ensure that tenant migrations always block all oplog entries other than commitIndexBuild and abortIndexBuild oplog entries. However, the current implementation could lead to invariant failure for batch insert that contains a doc with "commitIndexBuild" or "abortIndexBuild" as a field. We should change to check to only throw if the doc corresponds to an actual commitIndexBuild or abortIndexBuild oplog entry. Also, the check should only be done if tenant migrations are enabled and should uassert instead of invariant.