summaryrefslogtreecommitdiff
path: root/src/mongo/s/query/cluster_client_cursor_impl.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/s/query/cluster_client_cursor_impl.h')
-rw-r--r--src/mongo/s/query/cluster_client_cursor_impl.h22
1 files changed, 4 insertions, 18 deletions
diff --git a/src/mongo/s/query/cluster_client_cursor_impl.h b/src/mongo/s/query/cluster_client_cursor_impl.h
index 8064a45595b..2529254cfce 100644
--- a/src/mongo/s/query/cluster_client_cursor_impl.h
+++ b/src/mongo/s/query/cluster_client_cursor_impl.h
@@ -32,7 +32,6 @@
#include <memory>
#include <queue>
-#include "mongo/bson/bsonobj.h"
#include "mongo/executor/task_executor.h"
#include "mongo/s/query/cluster_client_cursor.h"
#include "mongo/s/query/cluster_client_cursor_guard.h"
@@ -117,11 +116,9 @@ public:
boost::optional<uint32_t> getQueryHash() const final;
- boost::optional<std::size_t> getQueryStatsKeyHash() const final;
+ std::uint64_t getNBatches() const final;
- bool getQueryStatsWillNeverExhaust() const final;
-
- std::unique_ptr<query_stats::Key> takeKey() final;
+ void incNBatches() final;
public:
/**
@@ -178,19 +175,8 @@ private:
// The hash of the query shape to be used for slow query logging;
boost::optional<uint32_t> _queryHash;
- // If boost::none, queryStats should not be collected for this cursor.
- boost::optional<std::size_t> _queryStatsKeyHash;
-
- // The Key used by query stats to generate the query stats store key.
- std::unique_ptr<query_stats::Key> _queryStatsKey;
-
- bool _queryStatsWillNeverExhaust = false;
-
- // Tracks if kill() has been called on the cursor. Multiple calls to kill() are treated as a
- // noop.
- // TODO SERVER-74482 investigate where kill() is called multiple times and remove unnecessary
- // calls
- bool _hasBeenKilled = false;
+ // The number of batches returned by this cursor.
+ std::uint64_t _nBatchesReturned = 0;
};
} // namespace mongo