summaryrefslogtreecommitdiff
path: root/jstests
diff options
context:
space:
mode:
authorXiangyu Yao <xiangyu.yao@mongodb.com>2018-11-05 17:13:45 -0500
committerXiangyu Yao <xiangyu.yao@mongodb.com>2018-11-19 11:24:19 -0500
commit9f117143be34ad7fc16ff7bbf259d95133ad2943 (patch)
treeec42494da39be5161e8d73f9fc16d6b72d91aedc /jstests
parent44f5c988dc1eb94ceaaa7d314b9b79819f8db6c4 (diff)
downloadmongo-9f117143be34ad7fc16ff7bbf259d95133ad2943.tar.gz
SERVER-37931 lock_stats_suboperation_logs.js should ignore noise lock stats
(cherry picked from commit d32a6a7ae38dffbdd4a2e4f5fe733831f07d93e8)
Diffstat (limited to 'jstests')
-rw-r--r--jstests/noPassthrough/lock_stats_suboperation_logs.js4
1 files changed, 4 insertions, 0 deletions
diff --git a/jstests/noPassthrough/lock_stats_suboperation_logs.js b/jstests/noPassthrough/lock_stats_suboperation_logs.js
index 515aad0baa7..9024f2ee179 100644
--- a/jstests/noPassthrough/lock_stats_suboperation_logs.js
+++ b/jstests/noPassthrough/lock_stats_suboperation_logs.js
@@ -77,6 +77,10 @@
for (let line of lines) {
if ((match = lockWaitTimeRegex.exec(line)) !== null) {
let lockWaitTime = match[1];
+ // Ignoring 'noise' lock stats from other operations such as locks taken during
+ // validation stage.
+ if (lockWaitTime < blockedMillis * 1000)
+ continue;
if (supposedLockWaitTime === undefined)
supposedLockWaitTime = lockWaitTime;
else