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

Embedded periodic jobs can access runner after destruction

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major - P3 Major - P3
    • 7.0.0-rc0
    • None
    • None
    • None
    • Fully Compatible
    • ALL
    • Execution Team 2023-03-06

    Description

      PeriodicRunnerEmbedded::PeriodicJobImpl holds a pointer to PeriodicRunnerEmbedded, and when the job is stopped it uses that pointer to take the mutex of the runner. This can be an issue because the periodic runner lives in the service context while the periodic job anchors often live in decorations on the service context; thus in these cases the periodic runner will be destructed before the job anchor. Then when the job anchor is destructed and attempts to stop, it will try to access the already-freed runner.

      Attachments

        Activity

          People

            gregory.noma@mongodb.com Gregory Noma
            gregory.noma@mongodb.com Gregory Noma
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: