Remove resharding's DonorStateEnum::kPreparingToBlockWrites state

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Fixed
    • Priority: Major - P3
    • 5.0.0-rc0
    • Affects Version/s: None
    • Component/s: Sharding
    • None
    • Fully Compatible
    • Sharding 2021-05-17
    • 1
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Donor shards engage the critical section on the collection being resharded during the shard version refresh with CoordinatorStateEnum::kBlockingWrites. Not engaging the critical section during the shard version refresh would be data loss because on recovery, from a primary failover, the donor shard would be allowing new incoming writes possibly after it had written the final resharding oplog entries already.

      The DonorStateEnum::kPreparingToBlockWrites state therefore provides no benefit and can safely be removed.

              Assignee:
              Haley Connelly
              Reporter:
              Max Hirschhorn
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: