mirror of
https://github.com/ton-blockchain/ton
synced 2025-03-09 15:40:10 +00:00
Fast-sync overlays
* Semiprivate overlays * Fast sync overlays in full-node * Adjust shard overlays
This commit is contained in:
parent
ac3b8d6088
commit
3a8ef60bbb
38 changed files with 2545 additions and 964 deletions
|
@ -68,7 +68,7 @@ td::Status BroadcastSimple::run_checks() {
|
|||
|
||||
td::Status BroadcastSimple::distribute() {
|
||||
auto B = serialize();
|
||||
auto nodes = overlay_->get_neighbours(3);
|
||||
auto nodes = overlay_->get_neighbours(overlay_->propagate_broadcast_to());
|
||||
|
||||
auto manager = overlay_->overlay_manager();
|
||||
for (auto &n : nodes) {
|
||||
|
@ -115,7 +115,8 @@ td::Status BroadcastSimple::run() {
|
|||
return run_continue();
|
||||
}
|
||||
|
||||
td::Status BroadcastSimple::create(OverlayImpl *overlay, adnl::AdnlNodeIdShort src_peer_id, tl_object_ptr<ton_api::overlay_broadcast> broadcast) {
|
||||
td::Status BroadcastSimple::create(OverlayImpl *overlay, adnl::AdnlNodeIdShort src_peer_id,
|
||||
tl_object_ptr<ton_api::overlay_broadcast> broadcast) {
|
||||
auto src = PublicKey{broadcast->src_};
|
||||
auto data_hash = sha256_bits256(broadcast->data_.as_slice());
|
||||
auto broadcast_hash = compute_broadcast_id(src, data_hash, broadcast->flags_);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue