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

WriteBatchExecutor doesn't handle PageFaultException during inserts.

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Blocker - P1
    • Resolution: Fixed
    • Affects Version/s: 2.6.0-rc1
    • Fix Version/s: 2.6.0-rc2
    • Component/s: Write Ops
    • Labels:
      None
    • Operating System:
      ALL
    • Steps To Reproduce:
      Hide

      Reliably fails the small oplog jsCore with write commands suite on Windows DEBUG builders.

      Show
      Reliably fails the small oplog jsCore with write commands suite on Windows DEBUG builders.
    • Linked BF Score:
      0

      Description

      All db record accesses that occur while a PageFaultRetryableSection is instantiated on a thread's stack must be wrapped in an exception handler for PageFaultException. WriteBatchExecutor::execInserts violates this rule, allowing PFE to escape up the stack, leading to server aborts when records are determined to not be in memory.

      Correct use of PFRS is as follows:

      bool done = false;
      PageFaultRetryableSection pFaultSection;
      while (!done) {
          try {
              DB*Lock myLock(dbname);
              // Do all operations involving record access here.
              ...
              done = true;
          }
          catch (const PageFaultException& pfe) {
              pfe.touch();
          }
      }

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              schwerin Andy Schwerin
              Reporter:
              schwerin Andy Schwerin
              Participants:
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: