CheckMetadataConsistency can target a secondary node whose ShardingState is not yet initialized

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Fixed
    • Priority: Major - P3
    • 9.1.0-rc0, 9.1.0-rc1022
    • Affects Version/s: 9.1.0-rc0, 9.0.0
    • Component/s: None
    • None
    • Catalog and Routing
    • Fully Compatible
    • ALL
    • v9.0
    • CAR Team 2026-09-14
    • 0
    • 🟥 DDL
    • None
    • None
    • None
    • None
    • None
    • None

      We made a first attempt to solve the issue where CMC can target a secondary node whose ShardingState is not yet initialized (SERVER-132376), but that only reduced the likelihood of it happening — there is still a race where the error can bubble up.

      Waiting on ShardingState::awaitClusterRoleRecovery is not enough to guarantee that subsequent accesses to ShardingState are safe: there's a tiny race where, even after waiting, the ShardingState is not yet ready.

            Assignee:
            Pol Pinol
            Reporter:
            Pol Pinol
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: