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

Improve CollatorNode

* Keep track of validator groups
* Pre-generate shard blocks
This commit is contained in:
SpyCheese 2024-06-25 14:06:15 +03:00
parent 3695bf0797
commit 90d2edf535
12 changed files with 410 additions and 174 deletions

View file

@ -575,8 +575,8 @@ td::Result<bool> Config::config_add_control_process(ton::PublicKeyHash key, td::
}
td::Result<bool> Config::config_add_shard(ton::ShardIdFull shard) {
if (!shard.is_valid_ext()) {
return td::Status::Error(PSTRING() << "invalid shard " << shard.to_str());
if (!shard.is_valid_ext() || shard.is_masterchain()) {
return td::Status::Error(PSTRING() << "invalid shard to collate " << shard.to_str());
}
if (std::find(shards_to_monitor.begin(), shards_to_monitor.end(), shard) != shards_to_monitor.end()) {
return false;