consensus: add calculation for proposal step waits from pbts #7290
consensus: add calculation for proposal step waits from pbts #7290williambanfield merged 9 commits intowb/proposer-based-timestampsfrom
Conversation
tychoish
left a comment
There was a problem hiding this comment.
the new functions in state.go aren't actually called in any non-test functions, are you planning on doing a separate integration pass?
yeah, I'd like to get all of the pieces in place first. Once things are integrated, they'll begin to impact consensus and I want to make sure it looks good/is correct before I actually do that. |
Co-authored-by: M. J. Fromberger <fromberger@interchain.io>
cason
left a comment
There was a problem hiding this comment.
I really did not understand the goal of the proposalStepWaitingTime method.
For me, the timeout propose event should be just scheduled to occur in timeout_propose duration plus proposalStepWaitingTime.
And if timeout_propose < 2 * Precision + msgDelay, well, we risk to prevote nil at a time at which we could still accept a timely Proposal. This is a poor choice of parameters, not a wrong behavior.
5375b89 to
6ee6f34
Compare
The EDIT: I'm realizing that liveness may be affected by just using |
cfc03ee to
57722da
Compare
* initial proposerWaitsUntil implementation * switch to duration for easier use with timeout scheduling * add proposal step waiting time with tests * minor aesthetic change to IsTimely * minor language fix * Update internal/consensus/state.go Co-authored-by: M. J. Fromberger <fromberger@interchain.io> * reword comment * change accuracy to precision * move tests to separate pbts test file Co-authored-by: M. J. Fromberger <fromberger@interchain.io>
* initial proposerWaitsUntil implementation * switch to duration for easier use with timeout scheduling * add proposal step waiting time with tests * minor aesthetic change to IsTimely * minor language fix * Update internal/consensus/state.go Co-authored-by: M. J. Fromberger <fromberger@interchain.io> * reword comment * change accuracy to precision * move tests to separate pbts test file Co-authored-by: M. J. Fromberger <fromberger@interchain.io>
This pull requests implements helper functions to for calculating sleep durations during the propose phase.
For more information on the inequalities in these functions, please see the proposer-based timestamps ADR. Specifically, this pull requests implements the proposer waits and changes to propose step timeout calculations.
Related to: #6942