RFC 12 Implementation: Reduce heartbeat probability to 6.25% #3759
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Refs: keep-network/tbtc-v2#737
The currently used probability of 12.5% means that a completely idle wallet will perform a heartbeat every 4 coordination windows on average (or 8 in the worst case) so, every 3600 blocks (~12 hours assuming a coordination every 900 blocks and 12 seconds per Ethereum block).
User acceptance tests executed on our Sepolia testnet (10 live wallets) show that such a value often leads to simultaneous heartbeats for several wallets at the same time. This, in turn, can cause increased resource consumption for individual nodes and harm some signing processes. Although nothing bad happens if those are just heartbeats, this may be problematic for redemptions and deposit sweeps. To lower the risk of signing failures, we are lowering the heartbeat probability to 6.25%.
The probability of 6.25% means that a completely idle wallet will perform a heartbeat every 8 coordination windows on average (or 16 in the worst case) so, every 7200 blocks (~24 hours assuming a coordination every 900 blocks and 12 seconds per Ethereum block).