Commit 1e9aa6d8 authored by Jeromy's avatar Jeromy

add in some extra debug logging, and increase routing table latencies

parent aea8c8b4
...@@ -11,6 +11,8 @@ import ( ...@@ -11,6 +11,8 @@ import (
u "github.com/jbenet/go-ipfs/util" u "github.com/jbenet/go-ipfs/util"
) )
var log = u.Logger("table")
// RoutingTable defines the routing table. // RoutingTable defines the routing table.
type RoutingTable struct { type RoutingTable struct {
...@@ -138,6 +140,8 @@ func (rt *RoutingTable) NearestPeer(id ID) *peer.Peer { ...@@ -138,6 +140,8 @@ func (rt *RoutingTable) NearestPeer(id ID) *peer.Peer {
if len(peers) > 0 { if len(peers) > 0 {
return peers[0] return peers[0]
} }
log.Error("NearestPeer: Returning nil, table size = %d", rt.Size())
return nil return nil
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment