diff options
author | Determinant <[email protected]> | 2018-08-02 20:26:21 -0400 |
---|---|---|
committer | Determinant <[email protected]> | 2018-08-02 20:26:21 -0400 |
commit | 4c42ac64c2ff821306609898a58126f2da32c7d4 (patch) | |
tree | be01d2f18b09fc056fa520b9ea548f1742a9781c /include/hotstuff/consensus.h | |
parent | 13c4335dc46fc1a4d6757279898347d99483dbfe (diff) |
WIP: sticky proposer pacemaker
Diffstat (limited to 'include/hotstuff/consensus.h')
-rw-r--r-- | include/hotstuff/consensus.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/hotstuff/consensus.h b/include/hotstuff/consensus.h index 1ff8f79..a373a2b 100644 --- a/include/hotstuff/consensus.h +++ b/include/hotstuff/consensus.h @@ -31,6 +31,7 @@ class HotStuffCore { /* === async event queues === */ std::unordered_map<block_t, promise_t> qc_waiting; promise_t propose_waiting; + promise_t receive_proposal_waiting; block_t get_delivered_blk(const uint256_t &blk_hash); void sanity_check_delivered(const block_t &blk); @@ -38,6 +39,7 @@ class HotStuffCore { bool update(const uint256_t &bqc_hash); void on_qc_finish(const block_t &blk); void on_propose_(const block_t &blk); + void on_deliver_blk_(const block_t &blk); protected: ReplicaID id; /**< identity of the replica itself */ @@ -125,6 +127,8 @@ class HotStuffCore { promise_t async_qc_finish(const block_t &blk); /** Get a promise resolved when a new block is proposed. */ promise_t async_wait_propose(); + /** Get a promise resolved when a new proposal is received. */ + promise_t async_wait_receive_proposal(); /* Other useful functions */ block_t get_genesis() { return b0; } |