Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Approval Distribution Subsystem #1951

Merged
merged 19 commits into from
Nov 25, 2020
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions roadmap/implementers-guide/src/node/utility/network-bridge.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,12 @@ The `activated` and `deactivated` lists determine the evolution of our local vie

If we are connected to the same peer on both peer-sets, we will send the peer two view updates as a result.

### Overseer Signal: BlockFinalized

We obtain the number of the block hash in the event by issuing a `ChainApiMessage::BlockNumber` request and then issue a `ProtocolMessage::ViewUpdate` to each connected peer on each peer-set. We also issue a `NetworkBridgeEvent::OurViewChange` to each event handler for each protocol.

If we are connected to the same peer on both peer-sets, we will send the peer two view updates as a result.

### Network Event: Peer Connected

Issue a `NetworkBridgeEvent::PeerConnected` for each [Event Handler](#event-handlers) of the peer-set and negotiated protocol version of the peer.
Expand Down
7 changes: 6 additions & 1 deletion roadmap/implementers-guide/src/types/network.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,12 @@ These types are those that are actually sent over the network to subsystems.
type RequestId = u64;
type ProtocolVersion = u32;
struct PeerId(...); // opaque, unique identifier of a peer.
struct View(Vec<Hash>); // Up to `N` (5?) chain heads.
struct View {
// Up to `N` (5?) chain heads.
heads: Vec<Hash>,
rphmeier marked this conversation as resolved.
Show resolved Hide resolved
// The number of the finalized block.
finalized_number: BlockNumber,
}

enum ObservedRole {
Full,
Expand Down