summaryrefslogtreecommitdiff
path: root/src/mongo/db/s/sharding_statistics.h
diff options
context:
space:
mode:
authorSarah Zhou <sarah.zhou@10gen.com>2018-07-31 17:36:22 -0400
committerSarah Zhou <sarah.zhou@10gen.com>2018-08-08 11:16:48 -0400
commit7a21994a8155f3b237f7c239798b55c7e9f67a7b (patch)
treecdacda2761a823eae5e4428f401b5eb1535f6ef5 /src/mongo/db/s/sharding_statistics.h
parent7dbc5c0b82b0d6454fc50d62ebcbaa11240f5ff0 (diff)
downloadmongo-7a21994a8155f3b237f7c239798b55c7e9f67a7b.tar.gz
SERVER-20865 Record sharding related counters in serverStatus
Diffstat (limited to 'src/mongo/db/s/sharding_statistics.h')
-rw-r--r--src/mongo/db/s/sharding_statistics.h26
1 files changed, 21 insertions, 5 deletions
diff --git a/src/mongo/db/s/sharding_statistics.h b/src/mongo/db/s/sharding_statistics.h
index c4eb7abd728..33849726bc5 100644
--- a/src/mongo/db/s/sharding_statistics.h
+++ b/src/mongo/db/s/sharding_statistics.h
@@ -41,21 +41,37 @@ class ServiceContext;
*/
struct ShardingStatistics {
// Counts how many times threads hit stale config exception (which is what triggers metadata
- // refreshes)
+ // refreshes).
AtomicInt64 countStaleConfigErrors{0};
- // Cumulative, always-increasing counter of how many chunks did this node start donating
- // (whether they succeeded or not)
+ // Cumulative, always-increasing counter of how many chunks this node has started to donate
+ // (whether they succeeded or not).
AtomicInt64 countDonorMoveChunkStarted{0};
// Cumulative, always-increasing counter of how much time the entire move chunk operation took
- // (excluding range deletion)
+ // (excluding range deletion).
AtomicInt64 totalDonorMoveChunkTimeMillis{0};
// Cumulative, always-increasing counter of how much time the clone phase took on the donor
- // node, before it was appropriate to enter the critical section
+ // node, before it was appropriate to enter the critical section.
AtomicInt64 totalDonorChunkCloneTimeMillis{0};
+ // Cumulative, always-increasing counter of how many documents have been cloned on the
+ // recipient node.
+ AtomicInt64 countDocsClonedOnRecipient{0};
+
+ // Cumulative, always-increasing counter of how many documents have been cloned on the donor
+ // node.
+ AtomicInt64 countDocsClonedOnDonor{0};
+
+ // Cumulative, always-increasing counter of how many documents have been deleted on the donor
+ // node by the rangeDeleter.
+ AtomicInt64 countDocsDeletedOnDonor{0};
+
+ // Cumulative, always-increasing counter of how many chunks this node started to receive
+ // (whether the receiving succeeded or not)
+ AtomicInt64 countRecipientMoveChunkStarted{0};
+
// Cumulative, always-increasing counter of how much time the critical section's commit phase
// took (this is the period of time when all operations on the collection are blocked, not just
// the reads)