Felix Lange
96ae35e2ac
p2p, p2p/discover, p2p/nat: rework logging using context keys
8 years ago
Péter Szilágyi
d4fd06c3dc
all: blidly swap out glog to our log15, logs need rework
8 years ago
Felix Lange
f2da6581ba
all: fix issues reported by honnef.co/go/simple/cmd/gosimple
8 years ago
villesundell
c7442ef0d2
ethdb, p2p/discover: replace "alloted" with "allotted" ( #2785 )
8 years ago
Ricardo Catalinas Jiménez
436fc8d76a
all: Rename crypto.Sha3{,Hash}() to crypto.Keccak256{,Hash}()
...
As we aren't really using the standarized SHA-3
9 years ago
Felix Lange
b4374436f3
p2p/discover: fix race involving the seed node iterator
...
nodeDB.querySeeds was not safe for concurrent use but could be called
concurrenty on multiple goroutines in the following case:
- the table was empty
- a timed refresh started
- a lookup was started and initiated refresh
These conditions are unlikely to coincide during normal use, but are
much more likely to occur all at once when the user's machine just woke
from sleep. The root cause of the issue is that querySeeds reused the
same leveldb iterator until it was exhausted.
This commit moves the refresh scheduling logic into its own goroutine
(so only one refresh is ever active) and changes querySeeds to not use
a persistent iterator. The seed node selection is now more random and
ignores nodes that have not been contacted in the last 5 days.
9 years ago
Felix Lange
bfbcfbe4a9
all: fix license headers one more time
...
I forgot to update one instance of "go-ethereum" in commit 3f047be5a
.
9 years ago
Felix Lange
3f047be5aa
all: update license headers to distiguish GPL/LGPL
...
All code outside of cmd/ is licensed as LGPL. The headers
now reflect this by calling the whole work "the go-ethereum library".
9 years ago
Felix Lange
ea54283b30
all: update license information
9 years ago
Péter Szilágyi
64174f196f
p2p/discover: add support for counting findnode failures
10 years ago
Péter Szilágyi
cbd3ae6906
p2p/discover: fix #838 , evacuate self entries from the node db
10 years ago
Felix Lange
d2f119cf9b
p2p/discover: limit open files for node database
10 years ago
Felix Lange
72ab6d3255
p2p/discover: track sha3(ID) in Node
10 years ago
Péter Szilágyi
b569550a39
p2p/discover: fix api issues caused by leveldb update
10 years ago
Péter Szilágyi
4992765032
p2p/discover: fix goroutine leak due to blocking on sync.Once
10 years ago
Péter Szilágyi
437cf4b3ac
p2p/discover: add node expirer and related tests
10 years ago
Péter Szilágyi
a136e2bb22
p2p/discover: parametrize nodedb version, add persistency tests
10 years ago
Péter Szilágyi
75fd738dea
p2p/discover: drop a superfluous warning
10 years ago
Péter Szilágyi
85b4b44235
p2p/discover: use iterator based seeding, drop old protocol test
10 years ago
Péter Szilágyi
8de8f61d36
p2p/discover: write the basic tests, catch RLP bug
10 years ago
Péter Szilágyi
0201c04b95
p2p/discovery: fix issues raised in the nodeDb PR
10 years ago
Péter Szilágyi
8646365b42
cmd/bootnode, eth, p2p, p2p/discover: use a fancier db design
10 years ago