diff options
author | Adam Ierymenko <adam.ierymenko@gmail.com> | 2015-11-02 15:15:20 -0800 |
---|---|---|
committer | Adam Ierymenko <adam.ierymenko@gmail.com> | 2015-11-02 15:15:20 -0800 |
commit | 60ce886605c0298fc22dbce48beb106a96bd35e2 (patch) | |
tree | 4c8f1af9926765c3c8bd3f4ffa0d6d42fb9bbd04 /node/Cluster.hpp | |
parent | ab27a91b07278146975087e873577bed43793554 (diff) | |
download | infinitytier-60ce886605c0298fc22dbce48beb106a96bd35e2.tar.gz infinitytier-60ce886605c0298fc22dbce48beb106a96bd35e2.zip |
Tweak some timings for better reliability.
Diffstat (limited to 'node/Cluster.hpp')
-rw-r--r-- | node/Cluster.hpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/node/Cluster.hpp b/node/Cluster.hpp index 7d7a1ced..f1caa436 100644 --- a/node/Cluster.hpp +++ b/node/Cluster.hpp @@ -55,13 +55,18 @@ /** * How often should we announce that we have a peer? */ -#define ZT_CLUSTER_HAVE_PEER_ANNOUNCE_PERIOD ((ZT_PEER_ACTIVITY_TIMEOUT / 2) - 1000) +#define ZT_CLUSTER_HAVE_PEER_ANNOUNCE_PERIOD (ZT_PEER_DIRECT_PING_DELAY / 2) /** * Desired period between doPeriodicTasks() in milliseconds */ #define ZT_CLUSTER_PERIODIC_TASK_PERIOD 250 +/** + * How often to flush outgoing message queues (maximum interval) + */ +#define ZT_CLUSTER_FLUSH_PERIOD 500 + namespace ZeroTier { class RuntimeEnvironment; @@ -355,6 +360,7 @@ private: uint64_t _lastCleanedPeerAffinities; uint64_t _lastCheckedPeersForAnnounce; + uint64_t _lastFlushed; }; } // namespace ZeroTier |