Ethan Buchman
c4b695f78d
minor fixes from review
7 years ago
Ethan Buchman
feb3230160
some comments
7 years ago
Ethan Buchman
8e044b0e6d
p2p/addrbook: some comments
7 years ago
Ethan Buchman
40e93a5f9e
p2p/addrbook: fix addToOldBucket
7 years ago
Ethan Buchman
8c88cc017a
p2p/addrbook: addAddress returns error. more defensive PickAddress
7 years ago
Ethan Buchman
ed95cc160a
p2p/addrbook: simplify PickAddress
7 years ago
Ethan Buchman
2f067a3f65
p2p/addrbook: addrNew/Old -> bucketsNew/Old
7 years ago
Ethan Buchman
498a82784d
p2p/addrbook: comments
7 years ago
Emmanuel Odeke
62c1bc0a20
p2p: comment on the wg.Add before go saveRoutine()
Just noticed while auditing the code in p2p/addrbook.go,
wg.Add(1) but no subsequent defer.
@jaekwon and I had a discussion offline and we agreed to
comment about why the code was that way and why
we shouldn't move the wg.Add(1) into .saveRoutine() because
if go a.saveRoutine() isn't started before anyone invokes
a.Wait(), then we'd have raced a.saveRoutine().
7 years ago
Anton Kaliaev
b4ece65726
standardize key for errors (should be "err")
8 years ago
zramsay
cf31f8d06f
core: apply megacheck vet tool (unused, gosimple, staticcheck)
8 years ago
Anton Kaliaev
f803544195
new logging
8 years ago
Ethan Buchman
57151d6043
p2p: use cmn instead of .
8 years ago
Ethan Buchman
23a6a6f8fc
move into p2p package
8 years ago
Ethan Buchman
eaeb547938
use tmlibs
8 years ago
Anton Kaliaev
5ab8ca0868
fix race
8 years ago
Anton Kaliaev
4c0d1d3ad2
return wg to addrbook
8 years ago
Anton Kaliaev
0277e52bd5
fix merge
8 years ago
Anton Kaliaev
cf18bf2966
add public RemoveAddress API
after discussion with @ebuchman (https://github.com/tendermint/go-p2p/pull/10#discussion_r96471729 )
8 years ago
Anton Kaliaev
590efc1040
call saveToFile OnStop
This is better than waiting because while we wait, anything could happen
(crash, timeout of the code who's using addrbook, ...). If we save
immediately, we have much greater chances of success.
8 years ago
Ethan Buchman
beb3eda438
fix addrbook start/stop
8 years ago
Ethan Buchman
88b5c724f2
remove public addr book funcs from pex
8 years ago
Anton Kalyaev
e7656873c1
public save API
8 years ago
Jae Kwon
bd353e004a
QuitService->BaseService
8 years ago
Ethan Buchman
2cee364692
addrbook: toggle strict routability
8 years ago
Jae Kwon
10619248c6
Use go-crypto CRand*
9 years ago
Jae Kwon
c37e25e76b
Conform to go-common WriteFile*(path, mode)
9 years ago
Jae Kwon
1c628a97ad
Conform to go-wire 1.0
9 years ago
Jae Kwon
abc3a2cc3c
initial commit
9 years ago