mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-24 05:36:46 +00:00
eth: reduce parallel lookups to 2
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
This commit is contained in:
parent
7bebcd1043
commit
e5af7d1c65
1 changed files with 4 additions and 2 deletions
|
|
@ -77,8 +77,10 @@ const (
|
||||||
// sources (disc/v4 and disc/v5). We set this number large enough to be able to
|
// sources (disc/v4 and disc/v5). We set this number large enough to be able to
|
||||||
// feed the dial queue with enough peers. Since the whole discovery process is triggered
|
// feed the dial queue with enough peers. Since the whole discovery process is triggered
|
||||||
// only when dial candidates are needed, we can keep this number high without worrying
|
// only when dial candidates are needed, we can keep this number high without worrying
|
||||||
// about overloading the DHT.
|
// about overloading the DHT. Only caveat is that in a small network, where maxpeers is
|
||||||
discoveryParallelLookups = 3
|
// higher than the actual number of nodes, this may lead to continuous lookups. We don't
|
||||||
|
// yet have a self-tuning solution for this, so we keep the value at 2.
|
||||||
|
discoveryParallelLookups = 2
|
||||||
|
|
||||||
// discoveryPrefetchBuffer is the number of peers to pre-fetch from a discovery
|
// discoveryPrefetchBuffer is the number of peers to pre-fetch from a discovery
|
||||||
// source. It is useful to avoid the negative effects of potential longer timeouts
|
// source. It is useful to avoid the negative effects of potential longer timeouts
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue