Handle invariants and MONGO_UNREACHABLE in cluster role class

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Fixed
    • Priority: Major - P3
    • 8.2.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Catalog and Routing
    • Fully Compatible
    • CAR Team 2025-06-09
    • 1
    • None
    • 3
    • TBD
    • 🟩 Routing and Topology
    • None
    • None
    • None
    • None
    • None
    • None
    • 0

      There is a MONGO_UNREACHABLE in the cluster role class which seems to be very reachable if a caller of the function provides an incorrect cluster role value. We should likely change this to a MONGO_UNREACHABLE_TASSERT to prevent crashes in case of an incorrect usage of this function in production.

      The class additionally contains an invariant to enforce that config servers must also include the role shard server. We should consider whether this could be accidentally violated by a user creating a cluster role for something other than a node's actual cluster role and thus whether the invariant should be converted to a tassert.

            Assignee:
            Wolfee Farkas
            Reporter:
            Allison Easton
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: