Merged
Conversation
There was a problem hiding this comment.
Pull request overview
This PR introduces significant updates to the TON Rust node's Simplex consensus implementation, focusing on protocol enhancements for broadcast messaging, session lifecycle management, and configuration restructuring. The changes maintain backward compatibility while enabling improved consensus operation through optional broadcast metadata transmission and controlled session initialization.
Changes:
- Enhanced broadcast protocol with optional
extrametadata field to support consensus.broadcastExtra containing slot information in two-step broadcasts - Introduced
Session::start()gate to defer FSM timeout clock until explicitly signaled, allowing overlays to warm up peer connections before consensus processing begins - Refactored SimplexConfig to separate critical fields (use_quic, slots_per_leader_window) from tunable parameters in NoncriticalParams with backward compatibility for v1/v2 deserialization
- Updated all ConsensusOverlay implementations to support new broadcast metadata parameter consistently across 8+ implementations
- Updated test infrastructure including test helper method renames and QuicNode constructor parameter additions
- Enhanced validator session listener with atomic stalled flag management for improved state tracking
Reviewed changes
Copilot reviewed 69 out of 69 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/tl/ton_api/tl/ton_api.tl | Added extra:bytes fields to two-step broadcast types and new consensus.broadcastExtra type definition |
| src/adnl/src/overlay/broadcast.rs | Implemented extra field handling in BroadcastTwostepFecProtocol and BroadcastTwostepSimpleProtocol |
| src/adnl/src/overlay/mod.rs | Added broadcast_twostep method with extra parameter routing to protocol implementations |
| src/node/consensus-common/src/lib.rs | Added Session::start() method to trait and send_broadcast_fec_ex with extra parameter |
| src/node/validator-session/src/session.rs | Implemented Session trait with start() method and LoopbackOverlay with extra parameter support |
| src/node/tests/compat_test/src/test_helpers.rs | Updated broadcast method signatures and QuicNode constructor calls |
| src/node/tests/compat_test/tests/test_twostep_fec_relay.rs | Renamed send_broadcast_two_step to send_broadcast_twostep |
| src/node/src/validator/validator_session_listener.rs | Added g.stalled atomic flag management with Ordering::Relaxed |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Sumrachek
approved these changes
Apr 1, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.