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

Retrying setAllowMigrations command may end up in a deadlock

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 7.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None
    • Fully Compatible
    • ALL
    • Sharding EMEA 2023-06-26, Sharding EMEA 2023-07-10
    • 140

      Retrying the setAllowMigrations command with a session and a txnNum (retryableWrite:true) may end up with a deadlock, competing for a session checkout and the _kChunkOpLock acquisition, as it's shown below:

       

      First cmd: session checkout > lock _kChunkOpLock > session check-in > transaction happenssession checkout > unlock _kChunkOpLock
      Second cmd: session checkout > lock _kChunkOpLock > session check-in > transaction happens > session checkout > unlock _kChunkOpLock

            Assignee:
            marcos.grillo@mongodb.com Marcos José Grillo Ramirez
            Reporter:
            silvia.surroca@mongodb.com Silvia Surroca
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: