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

Magic restore unnecessarily keeps a collection acquired

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 8.1.0-rc0
    • Affects Version/s: None
    • Component/s: Internal Code
    • None
    • Replication
    • Fully Compatible
    • ALL
    • v8.0
    • Repl 2025-02-17
    • 200
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      The code here keeps an AutoGetCollection acquired unnecessarily long:

      https://github.com/10gen/mongo/blob/ed405958353e2d940fd23e4488cc4af722f168c3/src/mongo/db/modules/enterprise/src/magic_restore/magic_restore.cpp#L715-L735

      We should ideally release the AutoGet as soon as possible to avoid having locks on two collections at the same time since it otherwise triggers a lock dependency inversion that SERVER-99150 detects (config -> admin database).

            Assignee:
            ali.mir@mongodb.com Ali Mir
            Reporter:
            jordi.olivares-provencio@mongodb.com Jordi Olivares Provencio
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved:
              None
              None
              None
              None