ReplicationCoordinator::awaitReplication should fail with correct error if called on a non-primary node

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Unresolved
    • Priority: Minor - P4
    • None
    • Affects Version/s: None
    • Component/s: Replication
    • Replication
    • ALL
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      The comments of ReplicationCoordinator::awaitReplication indicate that a NotMaster error code should be returned if called on a node that is not in primary state. The method's logic, however, does not align with this. If called from a secondary, the method will trivially fail with a PrimarySteppedDown error message, which seems incorrect. We should fix this and make sure to clarify this method's pre-condition i.e. that it is only valid to call it on a primary node, if that is the intended behavior.

              Assignee:
              [DO NOT USE] Backlog - Replication Team
              Reporter:
              Will Schultz
              Votes:
              0 Vote for this issue
              Watchers:
              11 Start watching this issue

                Created:
                Updated: