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

maxTimeNeverTimeOut failPoint not invoked for a linearizable readConcern

    • Type: Icon: Bug Bug
    • Resolution: Won't Fix
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 3.5.1
    • Component/s: Replication
    • Replication
    • ALL

      The test jstests/core/max_time_ms.js fails when run in the linearizable readConcern override passthrough for the following test case:

      // maxTimeNeverTimeOut positive test for query.
      assert.eq(1,
                t.getDB().adminCommand({configureFailPoint: "maxTimeNeverTimeOut", mode: "alwaysOn"}).ok);
      t.drop();
      t.insert([{}, {}, {}]);
      cursor = t.find({
          $where: function() {
              sleep(100);
              return true;
          }
      });
      cursor.maxTimeMS(100);
      assert.doesNotThrow(function() {
          cursor.itcount();
      }, [], "expected query to trigger maxTimeNeverTimeOut fail point");
      assert.eq(1, t.getDB().adminCommand({configureFailPoint: "maxTimeNeverTimeOut", mode: "off"}).ok);
      
      [js_test:max_time_ms] 2017-01-11T15:31:55.044+0000 assert: threw unexpected exception: Error: error: {
      [ReplicaSetFixture:job0:primary] 2017-01-11T15:31:55.042+0000 I COMMAND  [conn92] command test.max_time_ms appName: "MongoDB Shell" command: find { find: "max_time_ms", filter: { $where: function () {
      [js_test:max_time_ms] 2017-01-11T15:31:55.047+0000 	"ok" : 0,
      [js_test:max_time_ms] 2017-01-11T15:31:55.047+0000 	"errmsg" : "operation exceeded time limit",
      [js_test:max_time_ms] 2017-01-11T15:31:55.048+0000 	"code" : 50,
      [js_test:max_time_ms] 2017-01-11T15:31:55.048+0000 	"codeName" : "ExceededTimeLimit"
      [js_test:max_time_ms] 2017-01-11T15:31:55.049+0000 } : expected query to trigger maxTimeNeverTimeOut fail point
      [js_test:max_time_ms] 2017-01-11T15:31:55.050+0000 doassert@src/mongo/shell/assert.js:18:14
      [js_test:max_time_ms] 2017-01-11T15:31:55.051+0000 assert.doesNotThrow@src/mongo/shell/assert.js:346:13
      

            Assignee:
            backlog-server-repl [DO NOT USE] Backlog - Replication Team
            Reporter:
            jonathan.abrahams Jonathan Abrahams
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: