If an update to a document's shard key value will cause the document to change shards, we throw a WouldChangeOwningShard exception. This ticket is to handle this error for updates sent as a part of a multi-statement transaction.
In order to do this, we need to catch and re-throw this error in ServiceEntryPointCommon. In BatchWriteExec::executeBatch(), we should not abort the transaction on this error. Instead, we should run the delete-insert transaction created as part of SERVER-39835.
If the update is not a part of a multi-stmt txn, we will error.
- is duplicated by
-
SERVER-37757 High verbosity log line in batch write path triggers invariant on bad top-level status
- Closed