-
Type: Bug
-
Resolution: Gone away
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
Catalog and Routing
-
ALL
-
CAR Team 2023-12-25, CAR Team 2024-01-08, CAR Team 2024-01-22
-
107
The current StaleConfig exceptions are a form of WriteConflictException which are a way for the ShardRole to indicate to the upstream RouterRole that it didn't route to the correct shard. By this definition, they should never escape the RouterRole loop, because there could be an upstream RouterRole loop which can incorrectly misinterpret the exception to mean it routed to the wrong place for one collection, while in fact the upstream router didn't even route to a ShardRole.
An example of this would be a recursive tree of $lookups operating on views.
In order to catch such exceptions wrongly propagated up the tree, the existing router role loop(s) have invariants here and here. Without this invariant, it is possible that the client of the router role loop (i.e., the lambda inside) makes a mistake and uses the routing info provided for namespace 1, but attaches it to namespace 2.
Currently, it is possible that a certain combination of {{$lookup}}s operating on views triggers this invariant.
This ticket is to introduce a different kind of StaleConfig exception which just indicates to the upstream router that it can retry and there is no action to be taken, such as refreshing.
- is related to
-
SERVER-74380 Router role retry loop should allow namespaces different from the one it was created for
- Closed