Commit b6800373 authored by luxq's avatar luxq

add log for kad connect.

parent 91e8417d
......@@ -122,6 +122,7 @@ inability to use, or your interaction with other nodes or the software.`)
bootNode := c.config.GetBool(optionNameBootnodeMode)
fullNode := c.config.GetBool(optionNameFullNode)
logger.Info("bootnode mode = ", bootNode)
if bootNode && !fullNode {
return errors.New("boot node must be started as a full node")
......@@ -139,6 +140,7 @@ inability to use, or your interaction with other nodes or the software.`)
}
bootnodes := c.config.GetStringSlice(optionNameBootnodes)
logger.Info("get bootnodes ", bootnodes)
blockTime := c.config.GetUint64(optionNameBlockTime)
networkConfig := getConfigByNetworkID(networkID, blockTime)
......
......@@ -628,6 +628,7 @@ func (k *Kad) Start(_ context.Context) error {
func (k *Kad) connectBootNodes(ctx context.Context) {
var attempts, connected int
totalAttempts := maxBootNodeAttempts * len(k.bootnodes)
k.logger.Debugf("connectBootNodes")
ctx, cancel := context.WithTimeout(ctx, 15*time.Second)
defer cancel()
......
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