-
Type: Bug
-
Resolution: Duplicate
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
Sharding NYC
-
ALL
-
15
Currently, in v4.2, when mongos shuts down, a batch write command can be interrupted by a CallbackCanceled error instead of InterruptedAtShutdown error and when that occurs, it returns a response without a top-level error as follows:
{"n" : 0, "ok": 1, "writeErrors" : [{"index" : 0, "code" : 90, "codeName" : "CallbackCanceled", "errmsg" : "Write results unavailable from ... :: caused by :: Callback canceled"}]}
SERVER-55648 was meant to solve this but we had mistakenly assumed that CallbackCanceled cannot be thrown on shutdown if cancelation token does not exist. Since we are not attaching the RetryableWriteError label in 4.2, we should catch the CallbackCanceled here and throw a shutdown error so drivers can retry.
- duplicates
-
SERVER-64642 Fix error where mongos returns CallbackCanceled and not InterruptedAtShutdown on shutdown
- Closed
- is related to
-
SERVER-53624 4.4 mongos does not attach RetryableWriteError label to shutdown errors
- Closed
-
SERVER-55648 Mongos doesn't return top-level batch-write error in case of shutdown
- Closed