summaryrefslogtreecommitdiff
path: root/node/Node.hpp
diff options
context:
space:
mode:
authorAdam Ierymenko <adam.ierymenko@gmail.com>2019-03-19 16:43:43 -0700
committerAdam Ierymenko <adam.ierymenko@gmail.com>2019-03-19 16:43:43 -0700
commit63ec19674c423b3d93185a690cff3f355c8d9c17 (patch)
tree2bbef2c69d0434ca95e9f952debf8aa2e9c6ad6d /node/Node.hpp
parent087c75d5eebea46be5a877dbd22c2362ad0a9051 (diff)
downloadinfinitytier-63ec19674c423b3d93185a690cff3f355c8d9c17.tar.gz
infinitytier-63ec19674c423b3d93185a690cff3f355c8d9c17.zip
.
Diffstat (limited to 'node/Node.hpp')
-rw-r--r--node/Node.hpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/node/Node.hpp b/node/Node.hpp
index c3e46deb..a6f92eb1 100644
--- a/node/Node.hpp
+++ b/node/Node.hpp
@@ -273,6 +273,12 @@ public:
return false;
}
+ inline void statsLogVerb(const unsigned int v,const unsigned int bytes)
+ {
+ ++_stats.inVerbCounts[v];
+ _stats.inVerbBytes[v] += (uint64_t)bytes;
+ }
+
private:
RuntimeEnvironment _RR;
RuntimeEnvironment *RR;
@@ -286,6 +292,9 @@ private:
// Time of last identity verification indexed by InetAddress.rateGateHash() -- used in IncomingPacket::_doHELLO() via rateGateIdentityVerification()
int64_t _lastIdentityVerification[16384];
+ // Statistics about stuff happening
+ volatile ZT_NodeStatistics _stats;
+
// Map that remembers if we have recently sent a network config to someone
// querying us as a controller.
struct _LocalControllerAuth