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

Update findAndModify FSM workloads to handle not matching anything

    XMLWordPrintable

    Details

    • Backwards Compatibility:
      Fully Compatible
    • Operating System:
      ALL
    • Backport Completed:
    • Steps To Reproduce:
      Hide

      python buildscripts/resmoke.py --executor=concurrency jstests/concurrency/fsm_all_simultaneous.js --storageEngine=mmapv1
      

      To force a yield*.js workload to be run in combination with every other FSM workload, the following patch can be applied:

      diff --git a/jstests/concurrency/fsm_all_simultaneous.js b/jstests/concurrency/fsm_all_simultaneous.js
      index e50e486..abe9a7d 100644
      --- a/jstests/concurrency/fsm_all_simultaneous.js
      +++ b/jstests/concurrency/fsm_all_simultaneous.js
      @@ -16,6 +16,6 @@ var blacklist = [
           'agg_sort_external.js', // uses >100MB of data, which can overwhelm test hosts
       ].map(function(file) { return dir + '/' + file; });
       
      -runWorkloadsInParallel(ls(dir).filter(function(file) {
      +runWorkloadsSerially(ls(dir).filter(function(file) {
           return !Array.contains(blacklist, file);
       }));
      diff --git a/jstests/concurrency/fsm_libs/runner.js b/jstests/concurrency/fsm_libs/runner.js
      index 09f788a..bebf316 100644
      --- a/jstests/concurrency/fsm_libs/runner.js
      +++ b/jstests/concurrency/fsm_libs/runner.js
      @@ -652,6 +652,7 @@ var runner = (function() {
                       bgThreadMgr.checkFailed(0);
       
                       var schedule = scheduleWorkloads(workloads, executionMode, executionOptions);
      +                schedule.forEach(workloads => workloads.unshift('jstests/concurrency/fsm_workloads/yield.js'));
                       printWorkloadSchedule(schedule, bgWorkloads);
       
                       schedule.forEach(function(workloads) {
      

      Show
      python buildscripts/resmoke.py --executor=concurrency jstests/concurrency/fsm_all_simultaneous.js --storageEngine=mmapv1 To force a yield*.js workload to be run in combination with every other FSM workload, the following patch can be applied: diff --git a/jstests/concurrency/fsm_all_simultaneous.js b/jstests/concurrency/fsm_all_simultaneous.js index e50e486..abe9a7d 100644 --- a/jstests/concurrency/fsm_all_simultaneous.js +++ b/jstests/concurrency/fsm_all_simultaneous.js @@ -16,6 +16,6 @@ var blacklist = [ 'agg_sort_external.js', // uses >100MB of data, which can overwhelm test hosts ].map(function(file) { return dir + '/' + file; }); -runWorkloadsInParallel(ls(dir).filter(function(file) { +runWorkloadsSerially(ls(dir).filter(function(file) { return !Array.contains(blacklist, file); })); diff --git a/jstests/concurrency/fsm_libs/runner.js b/jstests/concurrency/fsm_libs/runner.js index 09f788a..bebf316 100644 --- a/jstests/concurrency/fsm_libs/runner.js +++ b/jstests/concurrency/fsm_libs/runner.js @@ -652,6 +652,7 @@ var runner = (function() { bgThreadMgr.checkFailed(0); var schedule = scheduleWorkloads(workloads, executionMode, executionOptions); + schedule.forEach(workloads => workloads.unshift('jstests/concurrency/fsm_workloads/yield.js')); printWorkloadSchedule(schedule, bgWorkloads); schedule.forEach(function(workloads) {
    • Sprint:
      Query F (02/01/16)
    • Linked BF Score:
      0

      Description

      Failures have only been observed with the findAndModify_inc.js workload. This is fallout from SERVER-22002 that was triggered by the introduction of fsm_all_simultaneous.js (SERVER-21499). Any FSM workload can now be run when the recordNeedsFetchFail failpoint is enabled and yielding is configured to occur more often due to the effects of the yield*.js workloads.

      Task
      Logs

      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.378+0000 ----
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.379+0000 Workload(s) completed in 36630 ms: jstests/concurrency/fsm_workloads/plan_cache_drop_database.js jstests/concurrency/fsm_workloads/findAndModify_inc.js jstests/concurrency/fsm_workloads/indexed_insert_eval.js jstests/concurrency/fsm_workloads/distinct_projection.js jstests/concurrency/fsm_workloads/create_collection.js jstests/concurrency/fsm_workloads/update_multifield.js jstests/concurrency/fsm_workloads/indexed_insert_heterogeneous.js jstests/concurrency/fsm_workloads/indexed_insert_2d.js jstests/concurrency/fsm_workloads/yield_sort_merge.js jstests/concurrency/fsm_workloads/yield_and_hashed.js
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.379+0000 ----
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.380+0000
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.380+0000
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.380+0000 2016-01-27T15:19:50.380+0000 E QUERY    [thread1] Error: 1 thread threw
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.380+0000
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.381+0000         Foreground jstests/concurrency/fsm_workloads/findAndModify_inc.js
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.381+0000         Error: [1] != [undefined] are not equal : undefined
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.381+0000
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.381+0000         quietlyDoAssert@jstests/concurrency/fsm_libs/assert.js:53:15
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.381+0000         assert.eq@src/mongo/shell/assert.js:49:5
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.381+0000         wrapAssertFn@jstests/concurrency/fsm_libs/assert.js:60:13
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.381+0000         assertWithLevel/</assertWithLevel[fn]@jstests/concurrency/fsm_libs/assert.js:99:13
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.382+0000         find/<@jstests/concurrency/fsm_workloads/findAndModify_inc.js:37:17
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.382+0000         assertWithLevel/assertWithLevel@jstests/concurrency/fsm_libs/assert.js:75:1
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.382+0000         find@jstests/concurrency/fsm_workloads/findAndModify_inc.js:35:1
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.382+0000         runFSM@jstests/concurrency/fsm_libs/fsm.js:43:13
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.382+0000         ____MongoToSM_newFunction_temp/<@:10:9
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.383+0000         main@jstests/concurrency/fsm_libs/worker_thread.js:104:17
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.383+0000         ____MongoToSM_newFunction_temp@:7:1
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.383+0000         ____MongoToSM_newFunction_temp@:5:24
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.383+0000
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.383+0000  :
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.383+0000 throwError@jstests/concurrency/fsm_libs/runner.js:332:23
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.383+0000 runWorkloads@jstests/concurrency/fsm_libs/runner.js:705:17
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.383+0000 parallel@jstests/concurrency/fsm_libs/runner.js:726:1
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.384+0000 @jstests/concurrency/fsm_all_simultaneous.js:19:1
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.384+0000
      [js_test:fsm_all_simultaneous] 2016-01-27T15:19:50.384+0000 failed to load: jstests/concurrency/fsm_all_simultaneous.js
      

        Attachments

          Issue Links

            Activity

              People

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

                Dates

                • Created:
                  Updated:
                  Resolved: