mirror of
https://github.com/codex-storage/nim-codex-dht.git
synced 2025-02-19 07:16:42 +00:00
log routing table size periodically
This commit is contained in:
parent
a3092dfde3
commit
591b270dc3
@ -938,6 +938,7 @@ proc revalidateLoop(d: Protocol) {.async.} =
|
|||||||
try:
|
try:
|
||||||
while true:
|
while true:
|
||||||
await sleepAsync(milliseconds(d.rng[].rand(RevalidateMax)))
|
await sleepAsync(milliseconds(d.rng[].rand(RevalidateMax)))
|
||||||
|
echo d.localNode.address.get().port, ": ", d.nodesDiscovered()
|
||||||
let n = d.routingTable.nodeToRevalidate()
|
let n = d.routingTable.nodeToRevalidate()
|
||||||
if not n.isNil:
|
if not n.isNil:
|
||||||
traceAsyncErrors d.revalidateNode(n)
|
traceAsyncErrors d.revalidateNode(n)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user