Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-91140

Improve comment on ShardingDDLCoodinator retrying even on InterruptedDueToReplStateChange

    • Type: Icon: Improvement Improvement
    • Resolution: Fixed
    • Priority: Icon: Trivial - P5 Trivial - P5
    • 8.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Catalog and Routing
    • Fully Compatible
    • CAR Team 2024-06-10, CAR Team 2024-06-24, CAR Team 2024-08-19, CAR Team 2024-09-02, CAR Team 2024-09-16, CAR Team 2024-09-30, CAR Team 2024-10-14

      ShardingDDLCoordinators retry ErrorCategory::Interruption, which includes InterruptedDueToReplStateChange. This causes the server to log a message  stating the coordinator is re-executing after InterruptedDueToReplStateChange error. ShardingDDLCoordinators are primary only, so this can be unexpected.

      Even if the re-execution is logged, the operation is eventually terminated. One reason for not excluding InterruptedDueToReplStateChange is the ambiguity between remote and local errors. It is possible InterruptedDueToReplStateChange is received from a remote node, in which case the operation should be retried. Another reason is that we just rely on the PrimaryOnlyService infrastructure properly shutting down during step down, instead of trying to detect specific errors to exit.

      We attempt to improve this comment to avoid future confusion.

            Assignee:
            yujin.kang@mongodb.com Yujin Kang Park
            Reporter:
            yujin.kang@mongodb.com Yujin Kang Park
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: