Skip to content

Commit

Permalink
GH-2045 Serialize all block_header_state and block_state data
Browse files Browse the repository at this point in the history
  • Loading branch information
heifner committed Jan 15, 2024
1 parent 03f2322 commit 7962634
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
8 changes: 5 additions & 3 deletions libraries/chain/include/eosio/chain/block_header_state.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,8 @@ using block_header_state_ptr = std::shared_ptr<block_header_state>;

}

// [greg todo] which members need to be serialized to disk when saving fork_db
// obviously many are missing below.
FC_REFLECT( eosio::chain::block_header_state, (id))
FC_REFLECT( eosio::chain::block_header_state_core,
(last_final_block_num)(final_on_strong_qc_block_num)(last_qc_block_num)(finalizer_policy_generation))
FC_REFLECT( eosio::chain::block_header_state,
(id)(header)(activated_protocol_features)(core)(proposal_mtree)(finality_mtree)
(active_finalizer_policy)(active_proposer_policy)(proposer_policies)(finalizer_policies)(header_exts))
3 changes: 1 addition & 2 deletions libraries/chain/include/eosio/chain/block_state.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -57,5 +57,4 @@ using block_state_ptr = std::shared_ptr<block_state>;

} // namespace eosio::chain

// [greg todo] which members need to be serialized to disk when saving fork_db
FC_REFLECT_DERIVED( eosio::chain::block_state, (eosio::chain::block_header_state), (block)(validated) )
FC_REFLECT_DERIVED( eosio::chain::block_state, (eosio::chain::block_header_state), (block)(validated)(strong_digest)(weak_digest)(pending_qc)(valid_qc) )

0 comments on commit 7962634

Please sign in to comment.