-
Type:
Task
-
Resolution: Unresolved
-
Priority:
Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
None
-
Query Integration
-
None
-
3
-
None
-
None
-
None
-
None
-
None
-
None
Add $match stage to filter for query operations in the $currentOp task of the DSI workloads/query-integration/currentOp performance test. The task should also add an assertion to check that we actually found query operations at a certain threshold in the test, i.e half way through the allotted run time we must assume $currentOp reported a query operation at some point.
The assertion could look something like:
pipeline = [ {"$currentOp": {}}, {"$match": {"op": "query", "active": True}} # adjust predicate as needed ] cursor = self.admin_database.aggregate(pipeline) ops = list(cursor) # Only assert after a warmup of 10 runs. if self.run_count > 10: assert ops, "No active query operations found."