2
0
Эх сурвалжийг харах

chore: add logging into DHT

Signed-off-by: mudler <[email protected]>
mudler 1 жил өмнө
parent
commit
d98ca254a0
1 өөрчлөгдсөн 2 нэмэгдсэн , 0 устгасан
  1. 2 0
      pkg/discovery/dht.go

+ 2 - 0
pkg/discovery/dht.go

@@ -109,10 +109,12 @@ func (d *DHT) Run(c log.StandardLogger, ctx context.Context, host host.Host) err
 	connect := func() {
 		d.bootstrapPeers(c, ctx, host)
 		if d.latestRendezvous != "" {
+			c.Debugf("Announcing with old rendezvous: %s", d.latestRendezvous)
 			d.announceAndConnect(c, ctx, kademliaDHT, host, d.latestRendezvous)
 		}
 
 		rv := d.Rendezvous()
+		c.Debugf("Announcing with current rendezvous: %s", d.latestRendezvous)
 		d.announceAndConnect(c, ctx, kademliaDHT, host, rv)
 	}