]> git.mxchange.org Git - quix0rs-apt-p2p.git/blobdiff - const.py
add some default bogus values in __init__
[quix0rs-apt-p2p.git] / const.py
index 0aad77d7ab46352a2899de55f7c6196f260bb207..1d3ee621b1bd355319085824adaeca1314077ba3 100644 (file)
--- a/const.py
+++ b/const.py
@@ -1,5 +1,17 @@
+from twisted.internet.default import SelectReactor ## twistedmatrix.com
 
-from twisted.internet.default import SelectReactor
 reactor = SelectReactor(installSignalHandlers=0)
 from twisted.internet import main
-main.installReactor(reactor)
\ No newline at end of file
+main.installReactor(reactor)
+
+# how many times a node can fail to respond before it's booted from the routing table
+MAX_FAILURES = 3
+
+# time before expirer starts running
+KEINITIAL_DELAY = 60 * 60 * 24 # 24 hours
+
+# time between expirer runs
+KE_DELAY = 60 * 60 # 1 hour
+
+# expire entries older than this
+KE_AGE = KEINITIAL_DELAY