Skip to content

Commit

Permalink
outbound-governor: randomness
Browse files Browse the repository at this point in the history
When outbound governor timeouts, we need have to update the `stdGen`
available in the outbound governor, so next time it has a chance to make
a different decision (known peers decisions use random selection between
light peer sharing (aka inbound peers) and peer sharing).
  • Loading branch information
coot committed Apr 30, 2024
1 parent 93d0fc5 commit 6dd7193
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -658,6 +658,6 @@ wakeupDecision :: PeerSelectionState peeraddr peerconn
wakeupDecision st _now =
Decision {
decisionTrace = [TraceGovernorWakeup],
decisionState = st,
decisionState = st { stdGen = fst (split (stdGen st)) } ,
decisionJobs = []
}

0 comments on commit 6dd7193

Please sign in to comment.