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

Set noCursorTimeout option on oplog cursor in ReplSetTest.prototype.checkOplogs()

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: 3.4.0-rc0
    • Fix Version/s: 3.4.5, 3.5.7
    • Component/s: Testing Infrastructure
    • Labels:
      None
    • Backwards Compatibility:
      Fully Compatible
    • Operating System:
      ALL
    • Backport Requested:
      v3.4
    • Steps To Reproduce:
      Hide

      python buildscripts/resmoke.py --executor=jstestfuzz_replication repro_server28868.js
      

      repro_server28868.js

      (function() {
          // Set the cursor timeout to a small value and have the cursor monitor check for expired cursors
          // more frequently.
          assert.commandWorked(db.adminCommand({setParameter: 1, cursorTimeoutMillis: 10}));
          assert.commandWorked(db.adminCommand({setParameter: 1, clientCursorMonitorFrequencySecs: 1}));
       
          // Insert some data to produce oplog entries.
          const bulk = db.mycoll.initializeUnorderedBulkOp();
          for (let i = 0; i < 10000; ++i) {
              bulk.insert({key: "x".repeat(5 * 1024)});
          };
          assert.writeOK(bulk.execute({w: 2}));
      })();
      

      Show
      python buildscripts/resmoke.py --executor=jstestfuzz_replication repro_server28868.js repro_server28868.js ( function () { // Set the cursor timeout to a small value and have the cursor monitor check for expired cursors // more frequently. assert.commandWorked(db.adminCommand({setParameter: 1, cursorTimeoutMillis: 10})); assert.commandWorked(db.adminCommand({setParameter: 1, clientCursorMonitorFrequencySecs: 1}));   // Insert some data to produce oplog entries. const bulk = db.mycoll.initializeUnorderedBulkOp(); for (let i = 0; i < 10000; ++i) { bulk.insert({key: "x" .repeat(5 * 1024)}); }; assert.writeOK(bulk.execute({w: 2})); })();
    • Sprint:
      TIG 2017-05-08
    • Linked BF Score:
      0

      Description

      It is possible that a test sets the "cursorTimeoutMillis" server parameter to a small value and never resets it to the default value of 10 minutes. Running the run_check_repl_oplog.js check after one of these tests can cause the cursor on the oplog to time out. We should set the noCursorTimeout option on the oplog cursor to prevent it from timing out.

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: