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

Range deleter processor must not try reschedule task during service shutdown

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 7.1.1, 7.2.0-rc0, 7.0.3
    • Affects Version/s: None
    • Component/s: Sharding
    • None
    • Fully Compatible
    • ALL
    • v7.1, v7.0
    • Sharding EMEA 2023-10-02
    • 152

      The range deleter service service shutdown procedure is:

      1. Set the state as down
      2. ....do some more stuff....
      3. Turn off the range deletions processor

      Hence when a range deletion throws IndexNotFound right while the service is stopping (between 1 and 3), it can happen that the processor tries to reschedule the task while the state is changing triggering this invariant.

      The solution is to hold the proper locks when emplacing the range deletion as it happens here or to simply change emplaceRangeDeletions to result in a no-op when called while the service is not up.

            Assignee:
            pierlauro.sciarelli@mongodb.com Pierlauro Sciarelli
            Reporter:
            pierlauro.sciarelli@mongodb.com Pierlauro Sciarelli
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: