mirror of
https://github.com/ton-blockchain/ton
synced 2025-03-09 15:40:10 +00:00
Accelerator, part 1 (#1119)
This commit contains some parts of https://github.com/ton-blockchain/ton/tree/accelerator This is auxiliary code that mostly does not change node behavior. 1) Semiprivate overlays and other improvements in overlays code 2) Rename actual_min_split -> monitor_min_split, fix building shard overlays 3) Loading block candidates by block id from DB, fix accept_block after validator restart 4) Cells: ProofStorageStat and changes in CellUsageTree 5) Remove some unused code, other minor changes
This commit is contained in:
parent
9a10f79fba
commit
908415d00b
66 changed files with 2221 additions and 638 deletions
|
@ -51,7 +51,7 @@ class ValidatorGroup : public td::actor::Actor {
|
|||
BlockIdExt create_next_block_id(RootHash root_hash, FileHash file_hash) const;
|
||||
BlockId create_next_block_id_simple() const;
|
||||
|
||||
void start(std::vector<BlockIdExt> prev, BlockIdExt min_masterchain_block_id, UnixTime min_ts);
|
||||
void start(std::vector<BlockIdExt> prev, BlockIdExt min_masterchain_block_id);
|
||||
void create_session();
|
||||
void destroy();
|
||||
void start_up() override {
|
||||
|
@ -114,7 +114,6 @@ class ValidatorGroup : public td::actor::Actor {
|
|||
|
||||
std::vector<BlockIdExt> prev_block_ids_;
|
||||
BlockIdExt min_masterchain_block_id_;
|
||||
UnixTime min_ts_;
|
||||
|
||||
td::Ref<ValidatorSet> validator_set_;
|
||||
BlockSeqno last_key_block_seqno_;
|
||||
|
@ -142,7 +141,7 @@ class ValidatorGroup : public td::actor::Actor {
|
|||
|
||||
void generated_block_candidate(std::shared_ptr<CachedCollatedBlock> cache, td::Result<BlockCandidate> R);
|
||||
|
||||
typedef std::tuple<td::Bits256, BlockIdExt, FileHash, FileHash> CacheKey;
|
||||
using CacheKey = std::tuple<td::Bits256, BlockIdExt, FileHash, FileHash>;
|
||||
std::map<CacheKey, UnixTime> approved_candidates_cache_;
|
||||
|
||||
void update_approve_cache(CacheKey key, UnixTime value);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue