diff options
author | Ian Boros <ian.boros@mongodb.com> | 2021-04-06 14:42:06 -0400 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2021-04-07 15:59:12 +0000 |
commit | a2f669d7a10dd26a76dca72035c313f41200ee66 (patch) | |
tree | c582d3a00933bc1810915b411a0237a3be8187c6 /jstests | |
parent | 27ee303a744b45ce205e8f1002e9d6b3783248dc (diff) | |
download | mongo-a2f669d7a10dd26a76dca72035c313f41200ee66.tar.gz |
SERVER-55091 Relax slowms/samplerate logging test to accomodate SBE
Diffstat (limited to 'jstests')
-rw-r--r-- | jstests/noPassthrough/log_format_slowms_samplerate_loglevel.js | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/jstests/noPassthrough/log_format_slowms_samplerate_loglevel.js b/jstests/noPassthrough/log_format_slowms_samplerate_loglevel.js index 968f79624e0..df21989d7b9 100644 --- a/jstests/noPassthrough/log_format_slowms_samplerate_loglevel.js +++ b/jstests/noPassthrough/log_format_slowms_samplerate_loglevel.js @@ -99,6 +99,11 @@ function runLoggingTests({db, readWriteMode, slowMs, logLevel, sampleRate}) { assert.commandWorked(db.setLogLevel(logLevel, "command")); assert.commandWorked(db.setLogLevel(logLevel, "write")); + const isSBEEnabled = (() => { + const getParam = db.adminCommand({getParameter: 1, featureFlagSBE: 1}); + return getParam.hasOwnProperty("featureFlagSBE") && getParam.featureFlagSBE.value; + })(); + // Certain fields in the log lines on mongoD are not applicable in their counterparts on // mongoS, and vice-versa. Ignore these fields when examining the logs of an instance on // which we do not expect them to appear. @@ -199,7 +204,8 @@ function runLoggingTests({db, readWriteMode, slowMs, logLevel, sampleRate}) { command: "find", find: coll.getName(), comment: logFormatTestComment, - planSummary: "IDHACK", + planSummary: isSBEEnabled && readWriteMode == "commands" ? "IXSCAN { _id: 1 }" + : "IDHACK", cursorExhausted: 1, keysExamined: 1, docsExamined: 1, @@ -389,7 +395,6 @@ function runLoggingTests({db, readWriteMode, slowMs, logLevel, sampleRate}) { comment: logFormatTestComment, collation: {locale: "fr"}, cursorExhausted: 1, - keysExamined: 4, docsExamined: 2, nreturned: 2, nShards: 1 |