-
Type:
Bug
-
Resolution: Fixed
-
Priority:
Major - P3
-
Affects Version/s: None
-
Component/s: None
-
None
-
Workload Resilience
-
Fully Compatible
-
Workload Resilience 2026-02-16
-
0
-
None
-
None
-
None
-
None
-
None
-
None
-
None
From https://jira.mongodb.org/browse/BF-41017
This part of the test set a failpoint to wait for 200ms(by default) before each yield. Run a find command touches 4 documents with batchSize 3.
The test waits until it hit failpoint 3 times then run shardDb.currentOp on the shard. Wait for operation to finish. Then it first checks the cumulative counter on router and the find ran on router is >= 1. And it fails when checking curOp to see if there was 1 find running.
failPoint.wait({timesEntered: 3});
const curOp = shardDb.currentOp({"command.comment": findComment, "command.find": "testColl", "active": true});
joinShell();
// Ensure that serverStatus indicates a find() was run.Add commentMore actions
{
const serverStatus = routerDb.serverStatus();
const findMetrics = serverStatus.metrics.commands["find"];
assert.gte(findMetrics.total, 1);
}
{
assert(
curOp.inprog.length === 1,
"Expected to find exactly one active find() command with the comment " + findComment,
); <----- the assert failure
This looks very much like a timing issue. After find op hit failpoint 3 times, and before shardDb.currentOp read the status, there's possibility the find op completed on shard, therefore there's no active find command.