diff options
Diffstat (limited to 'jstests/concurrency/fsm_workloads/indexed_insert_compound.js')
-rw-r--r-- | jstests/concurrency/fsm_workloads/indexed_insert_compound.js | 44 |
1 files changed, 21 insertions, 23 deletions
diff --git a/jstests/concurrency/fsm_workloads/indexed_insert_compound.js b/jstests/concurrency/fsm_workloads/indexed_insert_compound.js index a32fc084215..c704b6dd0bc 100644 --- a/jstests/concurrency/fsm_workloads/indexed_insert_compound.js +++ b/jstests/concurrency/fsm_workloads/indexed_insert_compound.js @@ -10,31 +10,29 @@ load('jstests/concurrency/fsm_libs/extend_workload.js'); // for extendWorkload load('jstests/concurrency/fsm_workloads/indexed_insert_base.js'); // for $config -var $config = - extendWorkload($config, - function($config, $super) { +var $config = extendWorkload($config, function($config, $super) { - $config.states.init = function init(db, collName) { - $super.states.init.apply(this, arguments); - }; + $config.states.init = function init(db, collName) { + $super.states.init.apply(this, arguments); + }; - $config.data.getDoc = function getDoc() { - return { - indexed_insert_compound_x: this.tid & 0x0f, // lowest 4 bits - indexed_insert_compound_y: this.tid >> 4, // high bits - indexed_insert_compound_z: String.fromCharCode(33 + this.tid) - }; - }; + $config.data.getDoc = function getDoc() { + return { + indexed_insert_compound_x: this.tid & 0x0f, // lowest 4 bits + indexed_insert_compound_y: this.tid >> 4, // high bits + indexed_insert_compound_z: String.fromCharCode(33 + this.tid) + }; + }; - $config.data.getIndexSpec = function getIndexSpec() { - return { - indexed_insert_compound_x: 1, - indexed_insert_compound_y: 1, - indexed_insert_compound_z: 1 - }; - }; + $config.data.getIndexSpec = function getIndexSpec() { + return { + indexed_insert_compound_x: 1, + indexed_insert_compound_y: 1, + indexed_insert_compound_z: 1 + }; + }; - $config.data.shardKey = $config.data.getIndexSpec(); + $config.data.shardKey = $config.data.getIndexSpec(); - return $config; - }); + return $config; +}); |