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

Race between oplog applier thread and index build coordinator thread leads to an invariant failure.

    • Type: Icon: Bug Bug
    • Resolution: Duplicate
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: Storage
    • None
    • ALL
    • v4.4
    • Execution Team 2020-04-06, Execution Team 2020-04-20

      A race can happen between oplog applier thread and index build coordinator thread and leading to this invariant failure. Oplog applier on receiving abortIndexBuild oplog entry performs the below steps.

      1) Oplog applier thread signals abort to index builder.
      2) Then calls the IndexBuildsCoordinator::_getIndexBuild() to get the ReplIndexBuildState for that index build.
      3) Then waits for the index build to complete by waiting on the ReplIndexBuildState:: sharedPromise

      Between step 1 and step 2, the index builder might have aborted and torn down the index build. In such cases, the step 2 would return "NoSuchKey" error.

            Assignee:
            louis.williams@mongodb.com Louis Williams
            Reporter:
            suganthi.mani@mongodb.com Suganthi Mani
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: