1
0
Fork 0
mirror of https://github.com/ton-blockchain/ton synced 2025-03-09 15:40:10 +00:00

added support for config change proposals

- added some fift scripts for the config change proposal voting
- added validator-engine-console support for the config change proposal voting
- additional sanity checks in catchain
- unsafe slow catchain resync method
This commit is contained in:
ton 2020-03-30 17:20:45 +04:00
parent a31f8d4424
commit 4dd5eea11f
35 changed files with 753 additions and 144 deletions

View file

@ -91,6 +91,9 @@ struct ValidatorManagerOptionsImpl : public ValidatorManagerOptions {
td::uint32 get_filedb_depth() const override {
return db_depth_;
}
bool check_unsafe_resync_allowed(CatchainSeqno seqno) const override {
return unsafe_catchains_.count(seqno) > 0;
}
void set_zero_block_id(BlockIdExt block_id) override {
zero_block_id_ = block_id;
@ -129,6 +132,9 @@ struct ValidatorManagerOptionsImpl : public ValidatorManagerOptions {
CHECK(value <= 32);
db_depth_ = value;
}
void add_unsafe_resync_catchain(CatchainSeqno seqno) override {
unsafe_catchains_.insert(seqno);
}
ValidatorManagerOptionsImpl *make_copy() const override {
return new ValidatorManagerOptionsImpl(*this);
@ -164,6 +170,7 @@ struct ValidatorManagerOptionsImpl : public ValidatorManagerOptions {
bool initial_sync_disabled_;
std::vector<BlockIdExt> hardforks_;
td::uint32 db_depth_ = 2;
std::set<CatchainSeqno> unsafe_catchains_;
};
} // namespace validator