{ "description": "operations ignore deprecated timeout options if timeoutMS is set", "schemaVersion": "1.9", "runOnRequirements": [ { "minServerVersion": "4.2", "topologies": [ "replicaset", "sharded" ] } ], "createEntities": [ { "client": { "id": "failPointClient", "useMultipleMongoses": false } } ], "initialData": [ { "collectionName": "coll", "databaseName": "test", "documents": [] } ], "tests": [ { "description": "commitTransaction ignores socketTimeoutMS if timeoutMS is set", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 20 }, "useMultipleMongoses": false, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "aggregate" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "commitTransaction" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "startTransaction", "object": "session" }, { "name": "countDocuments", "object": "collection", "arguments": { "filter": {}, "session": "session" } }, { "name": "commitTransaction", "object": "session", "arguments": { "timeoutMS": 10000 } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "commitTransaction", "databaseName": "admin", "command": { "commitTransaction": 1, "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "commitTransaction ignores wTimeoutMS if timeoutMS is set", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "aggregate" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "startTransaction", "object": "session" }, { "name": "countDocuments", "object": "collection", "arguments": { "filter": {}, "session": "session" } }, { "name": "commitTransaction", "object": "session", "arguments": { "timeoutMS": 10000 } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "commitTransaction", "databaseName": "admin", "command": { "commitTransaction": 1, "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "commitTransaction ignores maxCommitTimeMS if timeoutMS is set", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "useMultipleMongoses": false, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "aggregate" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "session": { "id": "session", "client": "client", "sessionOptions": { "defaultTransactionOptions": { "maxCommitTimeMS": 5000 } } } } ] } }, { "name": "startTransaction", "object": "session" }, { "name": "countDocuments", "object": "collection", "arguments": { "filter": {}, "session": "session" } }, { "name": "commitTransaction", "object": "session", "arguments": { "timeoutMS": 1000 } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "commitTransaction", "databaseName": "admin", "command": { "commitTransaction": 1, "maxTimeMS": { "$$lte": 1000 } } } } ] } ] }, { "description": "abortTransaction ignores socketTimeoutMS if timeoutMS is set", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 20 }, "useMultipleMongoses": false, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "aggregate" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "abortTransaction" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "startTransaction", "object": "session" }, { "name": "countDocuments", "object": "collection", "arguments": { "filter": {}, "session": "session" } }, { "name": "abortTransaction", "object": "session", "arguments": { "timeoutMS": 10000 } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "abortTransaction", "databaseName": "admin", "command": { "abortTransaction": 1, "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "abortTransaction ignores wTimeoutMS if timeoutMS is set", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "aggregate" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "startTransaction", "object": "session" }, { "name": "countDocuments", "object": "collection", "arguments": { "filter": {}, "session": "session" } }, { "name": "abortTransaction", "object": "session", "arguments": { "timeoutMS": 10000 } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "abortTransaction", "databaseName": "admin", "command": { "abortTransaction": 1, "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "withTransaction ignores socketTimeoutMS if timeoutMS is set", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 20 }, "useMultipleMongoses": false, "observeEvents": [ "commandStartedEvent" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "commitTransaction" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "withTransaction", "object": "session", "arguments": { "timeoutMS": 10000, "callback": [ { "name": "countDocuments", "object": "collection", "arguments": { "filter": {}, "session": "session" } } ] } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "aggregate", "databaseName": "test", "command": { "aggregate": "coll", "maxTimeMS": { "$$type": [ "int", "long" ] } } } }, { "commandStartedEvent": { "commandName": "commitTransaction", "databaseName": "admin", "command": { "commitTransaction": 1, "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "withTransaction ignores wTimeoutMS if timeoutMS is set", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "withTransaction", "object": "session", "arguments": { "timeoutMS": 10000, "callback": [ { "name": "countDocuments", "object": "collection", "arguments": { "filter": {}, "session": "session" } } ] } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "aggregate", "databaseName": "test", "command": { "aggregate": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } }, { "commandStartedEvent": { "commandName": "commitTransaction", "databaseName": "admin", "command": { "commitTransaction": 1, "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "withTransaction ignores maxCommitTimeMS if timeoutMS is set", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "useMultipleMongoses": false, "observeEvents": [ "commandStartedEvent" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "session": { "id": "session", "client": "client", "sessionOptions": { "defaultTransactionOptions": { "maxCommitTimeMS": 5000 } } } } ] } }, { "name": "withTransaction", "object": "session", "arguments": { "timeoutMS": 1000, "callback": [ { "name": "countDocuments", "object": "collection", "arguments": { "filter": {}, "session": "session" } } ] } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "aggregate", "databaseName": "test", "command": { "aggregate": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } }, { "commandStartedEvent": { "commandName": "commitTransaction", "databaseName": "admin", "command": { "commitTransaction": 1, "maxTimeMS": { "$$lte": 1000 } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - listDatabases on client", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "listDatabases" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "listDatabases", "object": "client", "arguments": { "timeoutMS": 100000, "filter": {} } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - listDatabases on client", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "listDatabases", "object": "client", "arguments": { "timeoutMS": 100000, "filter": {} } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "listDatabases", "databaseName": "admin", "command": { "listDatabases": 1, "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - listDatabaseNames on client", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "listDatabases" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "listDatabaseNames", "object": "client", "arguments": { "timeoutMS": 100000 } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - listDatabaseNames on client", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "listDatabaseNames", "object": "client", "arguments": { "timeoutMS": 100000 } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "listDatabases", "databaseName": "admin", "command": { "listDatabases": 1, "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - createChangeStream on client", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "aggregate" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "createChangeStream", "object": "client", "arguments": { "timeoutMS": 100000, "pipeline": [] } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - createChangeStream on client", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "createChangeStream", "object": "client", "arguments": { "timeoutMS": 100000, "pipeline": [] } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "aggregate", "databaseName": "admin", "command": { "aggregate": 1, "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - aggregate on database", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "aggregate" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "aggregate", "object": "database", "arguments": { "timeoutMS": 100000, "pipeline": [ { "$listLocalSessions": {} }, { "$limit": 1 } ] } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - aggregate on database", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "aggregate", "object": "database", "arguments": { "timeoutMS": 100000, "pipeline": [ { "$listLocalSessions": {} }, { "$limit": 1 } ] } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "aggregate", "databaseName": "test", "command": { "aggregate": 1, "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "maxTimeMS is ignored if timeoutMS is set - aggregate on database", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "useMultipleMongoses": false, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "aggregate", "object": "database", "arguments": { "timeoutMS": 1000, "maxTimeMS": 5000, "pipeline": [ { "$listLocalSessions": {} }, { "$limit": 1 } ] } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "aggregate", "databaseName": "test", "command": { "aggregate": 1, "maxTimeMS": { "$$lte": 1000 } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - listCollections on database", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "listCollections" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "listCollections", "object": "database", "arguments": { "timeoutMS": 100000, "filter": {} } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - listCollections on database", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "listCollections", "object": "database", "arguments": { "timeoutMS": 100000, "filter": {} } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "listCollections", "databaseName": "test", "command": { "listCollections": 1, "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - listCollectionNames on database", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "listCollections" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "listCollectionNames", "object": "database", "arguments": { "timeoutMS": 100000, "filter": {} } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - listCollectionNames on database", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "listCollectionNames", "object": "database", "arguments": { "timeoutMS": 100000, "filter": {} } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "listCollections", "databaseName": "test", "command": { "listCollections": 1, "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - runCommand on database", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "ping" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "runCommand", "object": "database", "arguments": { "timeoutMS": 100000, "command": { "ping": 1 }, "commandName": "ping" } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - runCommand on database", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "runCommand", "object": "database", "arguments": { "timeoutMS": 100000, "command": { "ping": 1 }, "commandName": "ping" } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "ping", "databaseName": "test", "command": { "ping": 1, "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - createChangeStream on database", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "aggregate" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "createChangeStream", "object": "database", "arguments": { "timeoutMS": 100000, "pipeline": [] } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - createChangeStream on database", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "createChangeStream", "object": "database", "arguments": { "timeoutMS": 100000, "pipeline": [] } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "aggregate", "databaseName": "test", "command": { "aggregate": 1, "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - aggregate on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "aggregate" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "aggregate", "object": "collection", "arguments": { "timeoutMS": 100000, "pipeline": [] } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - aggregate on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "aggregate", "object": "collection", "arguments": { "timeoutMS": 100000, "pipeline": [] } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "aggregate", "databaseName": "test", "command": { "aggregate": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "maxTimeMS is ignored if timeoutMS is set - aggregate on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "useMultipleMongoses": false, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "aggregate", "object": "collection", "arguments": { "timeoutMS": 1000, "maxTimeMS": 5000, "pipeline": [] } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "aggregate", "databaseName": "test", "command": { "aggregate": "coll", "maxTimeMS": { "$$lte": 1000 } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - count on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "count" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "count", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {} } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - count on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "count", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {} } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "count", "databaseName": "test", "command": { "count": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "maxTimeMS is ignored if timeoutMS is set - count on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "useMultipleMongoses": false, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "count", "object": "collection", "arguments": { "timeoutMS": 1000, "maxTimeMS": 5000, "filter": {} } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "count", "databaseName": "test", "command": { "count": "coll", "maxTimeMS": { "$$lte": 1000 } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - countDocuments on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "aggregate" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "countDocuments", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {} } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - countDocuments on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "countDocuments", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {} } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "aggregate", "databaseName": "test", "command": { "aggregate": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - estimatedDocumentCount on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "count" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "estimatedDocumentCount", "object": "collection", "arguments": { "timeoutMS": 100000 } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - estimatedDocumentCount on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "estimatedDocumentCount", "object": "collection", "arguments": { "timeoutMS": 100000 } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "count", "databaseName": "test", "command": { "count": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "maxTimeMS is ignored if timeoutMS is set - estimatedDocumentCount on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "useMultipleMongoses": false, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "estimatedDocumentCount", "object": "collection", "arguments": { "timeoutMS": 1000, "maxTimeMS": 5000 } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "count", "databaseName": "test", "command": { "count": "coll", "maxTimeMS": { "$$lte": 1000 } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - distinct on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "distinct" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "distinct", "object": "collection", "arguments": { "timeoutMS": 100000, "fieldName": "x", "filter": {} } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - distinct on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "distinct", "object": "collection", "arguments": { "timeoutMS": 100000, "fieldName": "x", "filter": {} } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "distinct", "databaseName": "test", "command": { "distinct": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "maxTimeMS is ignored if timeoutMS is set - distinct on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "useMultipleMongoses": false, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "distinct", "object": "collection", "arguments": { "timeoutMS": 1000, "maxTimeMS": 5000, "fieldName": "x", "filter": {} } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "distinct", "databaseName": "test", "command": { "distinct": "coll", "maxTimeMS": { "$$lte": 1000 } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - find on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "find" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "find", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {} } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - find on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "find", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {} } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "find", "databaseName": "test", "command": { "find": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "maxTimeMS is ignored if timeoutMS is set - find on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "useMultipleMongoses": false, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "find", "object": "collection", "arguments": { "timeoutMS": 1000, "maxTimeMS": 5000, "filter": {} } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "find", "databaseName": "test", "command": { "find": "coll", "maxTimeMS": { "$$lte": 1000 } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - findOne on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "find" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "findOne", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {} } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - findOne on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "findOne", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {} } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "find", "databaseName": "test", "command": { "find": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "maxTimeMS is ignored if timeoutMS is set - findOne on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "useMultipleMongoses": false, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "findOne", "object": "collection", "arguments": { "timeoutMS": 1000, "maxTimeMS": 5000, "filter": {} } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "find", "databaseName": "test", "command": { "find": "coll", "maxTimeMS": { "$$lte": 1000 } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - listIndexes on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "listIndexes" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "listIndexes", "object": "collection", "arguments": { "timeoutMS": 100000 } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - listIndexes on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "listIndexes", "object": "collection", "arguments": { "timeoutMS": 100000 } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "listIndexes", "databaseName": "test", "command": { "listIndexes": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - listIndexNames on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "listIndexes" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "listIndexNames", "object": "collection", "arguments": { "timeoutMS": 100000 } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - listIndexNames on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "listIndexNames", "object": "collection", "arguments": { "timeoutMS": 100000 } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "listIndexes", "databaseName": "test", "command": { "listIndexes": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - createChangeStream on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "aggregate" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "createChangeStream", "object": "collection", "arguments": { "timeoutMS": 100000, "pipeline": [] } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - createChangeStream on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "createChangeStream", "object": "collection", "arguments": { "timeoutMS": 100000, "pipeline": [] } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "aggregate", "databaseName": "test", "command": { "aggregate": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - insertOne on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "insert" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "insertOne", "object": "collection", "arguments": { "timeoutMS": 100000, "document": { "x": 1 } } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - insertOne on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "insertOne", "object": "collection", "arguments": { "timeoutMS": 100000, "document": { "x": 1 } } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "insert", "databaseName": "test", "command": { "insert": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - insertMany on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "insert" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "insertMany", "object": "collection", "arguments": { "timeoutMS": 100000, "documents": [ { "x": 1 } ] } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - insertMany on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "insertMany", "object": "collection", "arguments": { "timeoutMS": 100000, "documents": [ { "x": 1 } ] } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "insert", "databaseName": "test", "command": { "insert": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - deleteOne on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "delete" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "deleteOne", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {} } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - deleteOne on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "deleteOne", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {} } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "delete", "databaseName": "test", "command": { "delete": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - deleteMany on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "delete" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "deleteMany", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {} } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - deleteMany on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "deleteMany", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {} } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "delete", "databaseName": "test", "command": { "delete": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - replaceOne on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "update" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "replaceOne", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {}, "replacement": { "x": 1 } } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - replaceOne on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "replaceOne", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {}, "replacement": { "x": 1 } } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "update", "databaseName": "test", "command": { "update": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - updateOne on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "update" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "updateOne", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {}, "update": { "$set": { "x": 1 } } } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - updateOne on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "updateOne", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {}, "update": { "$set": { "x": 1 } } } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "update", "databaseName": "test", "command": { "update": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - updateMany on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "update" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "updateMany", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {}, "update": { "$set": { "x": 1 } } } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - updateMany on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "updateMany", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {}, "update": { "$set": { "x": 1 } } } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "update", "databaseName": "test", "command": { "update": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - findOneAndDelete on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "findAndModify" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "findOneAndDelete", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {} } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - findOneAndDelete on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "findOneAndDelete", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {} } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "findAndModify", "databaseName": "test", "command": { "findAndModify": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "maxTimeMS is ignored if timeoutMS is set - findOneAndDelete on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "useMultipleMongoses": false, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "findOneAndDelete", "object": "collection", "arguments": { "timeoutMS": 1000, "maxTimeMS": 5000, "filter": {} } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "findAndModify", "databaseName": "test", "command": { "findAndModify": "coll", "maxTimeMS": { "$$lte": 1000 } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - findOneAndReplace on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "findAndModify" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "findOneAndReplace", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {}, "replacement": { "x": 1 } } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - findOneAndReplace on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "findOneAndReplace", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {}, "replacement": { "x": 1 } } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "findAndModify", "databaseName": "test", "command": { "findAndModify": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "maxTimeMS is ignored if timeoutMS is set - findOneAndReplace on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "useMultipleMongoses": false, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "findOneAndReplace", "object": "collection", "arguments": { "timeoutMS": 1000, "maxTimeMS": 5000, "filter": {}, "replacement": { "x": 1 } } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "findAndModify", "databaseName": "test", "command": { "findAndModify": "coll", "maxTimeMS": { "$$lte": 1000 } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - findOneAndUpdate on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "findAndModify" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "findOneAndUpdate", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {}, "update": { "$set": { "x": 1 } } } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - findOneAndUpdate on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "findOneAndUpdate", "object": "collection", "arguments": { "timeoutMS": 100000, "filter": {}, "update": { "$set": { "x": 1 } } } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "findAndModify", "databaseName": "test", "command": { "findAndModify": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "maxTimeMS is ignored if timeoutMS is set - findOneAndUpdate on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "useMultipleMongoses": false, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "findOneAndUpdate", "object": "collection", "arguments": { "timeoutMS": 1000, "maxTimeMS": 5000, "filter": {}, "update": { "$set": { "x": 1 } } } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "findAndModify", "databaseName": "test", "command": { "findAndModify": "coll", "maxTimeMS": { "$$lte": 1000 } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - bulkWrite on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "insert" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "bulkWrite", "object": "collection", "arguments": { "timeoutMS": 100000, "requests": [ { "insertOne": { "document": { "_id": 1 } } } ] } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - bulkWrite on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "bulkWrite", "object": "collection", "arguments": { "timeoutMS": 100000, "requests": [ { "insertOne": { "document": { "_id": 1 } } } ] } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "insert", "databaseName": "test", "command": { "insert": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - createIndex on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "createIndexes" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "createIndex", "object": "collection", "arguments": { "timeoutMS": 100000, "keys": { "x": 1 }, "name": "x_1" } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - createIndex on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "createIndex", "object": "collection", "arguments": { "timeoutMS": 100000, "keys": { "x": 1 }, "name": "x_1" } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "createIndexes", "databaseName": "test", "command": { "createIndexes": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "maxTimeMS is ignored if timeoutMS is set - createIndex on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "useMultipleMongoses": false, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "createIndex", "object": "collection", "arguments": { "timeoutMS": 1000, "maxTimeMS": 5000, "keys": { "x": 1 }, "name": "x_1" } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "createIndexes", "databaseName": "test", "command": { "createIndexes": "coll", "maxTimeMS": { "$$lte": 1000 } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - dropIndex on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "dropIndexes" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "createIndex", "object": "collection", "arguments": { "keys": { "x": 1 }, "timeoutMS": 100000, "name": "x_1" } }, { "name": "dropIndex", "object": "collection", "arguments": { "timeoutMS": 100000, "name": "x_1" } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - dropIndex on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "createIndex", "object": "collection", "arguments": { "keys": { "x": 1 }, "timeoutMS": 100000, "name": "x_1" } }, { "name": "dropIndex", "object": "collection", "arguments": { "timeoutMS": 100000, "name": "x_1" } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "createIndexes", "databaseName": "test" } }, { "commandStartedEvent": { "commandName": "dropIndexes", "databaseName": "test", "command": { "dropIndexes": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "maxTimeMS is ignored if timeoutMS is set - dropIndex on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "useMultipleMongoses": false, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "createIndex", "object": "collection", "arguments": { "keys": { "x": 1 }, "name": "x_1" } }, { "name": "dropIndex", "object": "collection", "arguments": { "timeoutMS": 1000, "maxTimeMS": 5000, "name": "x_1" } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "createIndexes", "databaseName": "test" } }, { "commandStartedEvent": { "commandName": "dropIndexes", "databaseName": "test", "command": { "dropIndexes": "coll", "maxTimeMS": { "$$lte": 1000 } } } } ] } ] }, { "description": "socketTimeoutMS is ignored if timeoutMS is set - dropIndexes on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "socketTimeoutMS": 1 }, "useMultipleMongoses": false } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "failPoint", "object": "testRunner", "arguments": { "client": "failPointClient", "failPoint": { "configureFailPoint": "failCommand", "mode": { "times": 1 }, "data": { "failCommands": [ "dropIndexes" ], "blockConnection": true, "blockTimeMS": 5 } } } }, { "name": "createIndex", "object": "collection", "arguments": { "keys": { "x": 1 }, "name": "x_1", "timeoutMS": 100000 } }, { "name": "dropIndexes", "object": "collection", "arguments": { "timeoutMS": 100000 } } ] }, { "description": "wTimeoutMS is ignored if timeoutMS is set - dropIndexes on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "uriOptions": { "wTimeoutMS": 1 }, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "dropIndexes", "object": "collection", "arguments": { "timeoutMS": 100000 } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "dropIndexes", "databaseName": "test", "command": { "dropIndexes": "coll", "writeConcern": { "$$exists": false }, "maxTimeMS": { "$$type": [ "int", "long" ] } } } } ] } ] }, { "description": "maxTimeMS is ignored if timeoutMS is set - dropIndexes on collection", "operations": [ { "name": "createEntities", "object": "testRunner", "arguments": { "entities": [ { "client": { "id": "client", "useMultipleMongoses": false, "observeEvents": [ "commandStartedEvent" ], "ignoreCommandMonitoringEvents": [ "killCursors" ] } }, { "database": { "id": "database", "client": "client", "databaseName": "test" } }, { "collection": { "id": "collection", "database": "database", "collectionName": "coll" } }, { "bucket": { "id": "bucket", "database": "database" } }, { "session": { "id": "session", "client": "client" } } ] } }, { "name": "dropIndexes", "object": "collection", "arguments": { "timeoutMS": 1000, "maxTimeMS": 5000 } } ], "expectEvents": [ { "client": "client", "events": [ { "commandStartedEvent": { "commandName": "dropIndexes", "databaseName": "test", "command": { "dropIndexes": "coll", "maxTimeMS": { "$$lte": 1000 } } } } ] } ] } ] }