mirror of
https://github.com/tendermint/tendermint.git
synced 2026-05-31 11:26:20 +00:00
expose 2 API functions for tendermint#node/node.go
This commit is contained in:
committed by
Ethan Buchman
parent
108beae7a8
commit
65b1756978
@@ -130,6 +130,16 @@ func (pexR *PEXReactor) SendAddrs(peer *Peer, addrs []*NetAddress) {
|
||||
peer.Send(PexChannel, struct{ PexMessage }{&pexAddrsMessage{Addrs: addrs}})
|
||||
}
|
||||
|
||||
// SaveAddrBook saves underlying address book
|
||||
func (r *PEXReactor) SaveAddrBook() {
|
||||
r.book.Save()
|
||||
}
|
||||
|
||||
// AddPeerAddress adds raw NetAddress to the address book
|
||||
func (r *PEXReactor) AddPeerAddress(peerAddr, srcAddr *NetAddress) {
|
||||
r.book.AddAddress(peerAddr, srcAddr)
|
||||
}
|
||||
|
||||
// Ensures that sufficient peers are connected. (continuous)
|
||||
func (pexR *PEXReactor) ensurePeersRoutine() {
|
||||
// Randomize when routine starts
|
||||
|
||||
Reference in New Issue
Block a user