The $_internalOwningShard expression should verify that the cached CollectionRoutingInfo has an initialised routing table before consuming it

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Fixed
    • Priority: Major - P3
    • 8.0.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Catalog and Routing
    • Fully Compatible
    • ALL
    • CAR Team 2024-03-18
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      The execution of the $_internalOwningShard aggregation expression requires the fetching of up-to-date routing information in a context that does not allow to wait for the completion of an inflight cache refresh.
      Such a logic should have to deal with situations where the returned CollectionRoutingInfo is stale or absent (this may happen in case $_internalOwningShard gets invoked right after the targeted collection gets sharded, which only triggers an asynchronous refresh of the routing info), but currently only the first condition is checked - and a tassert is instead hit when the latter one materialises.

              Assignee:
              Paolo Polato
              Reporter:
              Paolo Polato
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: