peers use uuid to avoid duplicate connections

This commit is contained in:
Ethan Buchman
2015-07-10 03:05:25 +00:00
parent 9521e4e4e7
commit d0610845dc
20 changed files with 1209 additions and 3 deletions

View File

@ -12,6 +12,7 @@ import (
"strings"
"time"
"github.com/tendermint/tendermint/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid"
"github.com/tendermint/tendermint/binary"
bc "github.com/tendermint/tendermint/blockchain"
. "github.com/tendermint/tendermint/common"
@ -242,6 +243,7 @@ func makeNodeInfo(sw *p2p.Switch) *types.NodeInfo {
ChainID: config.GetString("chain_id"),
Moniker: config.GetString("moniker"),
Version: config.GetString("version"),
UUID: uuid.New(),
}
// include git hash in the nodeInfo if available