-
Notifications
You must be signed in to change notification settings - Fork 110
swarm/network: hive SuggestPeer unit tests #1088
Conversation
…kademlia, test now "passes"
RetryInterval: 4200000000, // 4.2 sec | ||
//RetryExponent: 2, | ||
RetryExponent: 3, | ||
RetryExponent: 3, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why 3?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i just removed the commented one. was it 2 in the first place?
swarm/network/hive.go
Outdated
} | ||
|
||
func (h *Hive) isTimeForRetry(d *Peer) bool { | ||
// debug.PrintStack() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this comment is for getRetriesFromDuration
ON LINE 511
what is this?
div += (150000 - rand.Int63n(300000)) * div / 1000000
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not sure i understand the question. anyway removed by now
seqPo++ | ||
// stop if we reach depth, because peers from that point and deeper will be treated differently | ||
if po <= depth { | ||
if depth >= po { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lol. still
swarm/network/hive.go
Outdated
return callablePeers | ||
} | ||
|
||
func insertSort(arr []int, comp func(int, int) bool) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
?
Discontinued due to ethereum/go-ethereum#18404 |
No description provided.