See here for instructions on how to set up a full node.
- In its primary usage, RaptorCast is utilized by each leader to share its block proposal to all other validators in the active set. There is one primary RaptorCast group, consisting of all validators in the active set, with a leader that rotates.
- In its secondary usage, one validator from the active set supports a number of downstream full nodes, propagating every block proposal (received by it via primary RaptorCast) to its downstream listeners. There are many secondary RaptorCast groups - one per validator in the active set - and for each one, the leader is static.
Differences between primary and secondary RaptorCast
Secondary RaptorCast follows the same mechanism as primary RaptorCast. There are some differences, however. In Primary RaptorCast:- The participants are all validators
- The originator changes given that the leader can change (due to leader election)
- The “weights” on the other nodes are based on stake
- The originator of a group is fixed and always a validator
- Other than the above, the other participants are full nodes
- All nodes are equally weighted
How full nodes register for secondary RaptorCast
-
Full nodes start by peering with some of the validators. They do this by peering with the
bootstrap peers (aka other full nodes) specified in
node.toml(see later in this document for more details), then asking them for their peers, and repeating until they have the name records of the full validator set. -
If a validator has
enable_publisher = truein itsnode.toml, it will routinely send invites to the full nodes in its routing table (up tomax_group_size). These invites will request the full node to join the validator’s secondary RaptorCast group. -
A full node has the option to accept or reject. If a full node is in too many groups, it will reject.
This is controlled by the
max_num_groupparameter. - The validator will collect these accept/reject responses and confirm a group.
-
The group will last for
round_spanspecified in the validator’snode.toml(default: 240 rounds). As the group’s age approachesround_span, the validator will start sending invites for its next secondary RaptorCast group. - Full nodes can (and should) join multiple secondary RaptorCast groups for redundancy.
A full node can join a group even if it hasn’t finished syncing the state. Joining a group is
how a full node becomes aware of the current round. That information can, in turn, be used to adjust
the statesync target.
Configuring RaptorCast
General Recommendation
It is highly suggested that operators of validators have the node:- First be a full node with
enable_client = true - AND also configure the validator specific settings in
node.toml - Then convert to a validator via staking
Important Considerations
- Several of the settings below only apply to nodes that are operating as a validator
- Other apply only if the node is running as a full node
- That being said, it’s recommended that BOTH sets of settings be in the
node.toml
enable_client = true) then it will miss block updates and fall behind the ledger tip.
node.toml
Below is a snippet of a node.toml that applies to RaptorCast.
We’ve grouped the settings as “full node only”, “validator only” or “both”
We’ve also added comments to explain what each setting does
node.toml contains the following settings:
Additional options
Prioritized secondary RaptorCast inclusion
A full node may coordinate with a validator to be explicitly and consistently invited to that validator’s secondary RaptorCast group. To do this, the full node provides some information for the validator to include in its[fullnode_raptorcast.full_nodes_prioritized.identities] section. See
Validator Installation for details on what needs to
be provided. Note that this means the full node doesn’t have to rely on peer discovery to peer with
that validator.
Dedicated upstream
Validators also have the option of specifying full nodes to which they wish to directly forward all primary RaptorCast chunks. This utilizes a lot of validator bandwidth, since each registered downstream requires another copy of all chunks to be sent. It is potentially more reliable for the downstream node than subscribing via secondary RaptorCast, although in practice secondary RaptorCast is quite reliable. Note that if a full node is designated by one or more validators for dedicated chunk forwarding, then it could be configured withenable_client = false. This turns off attempting to participate
in secondary RaptorCast.
Comparison
| Configuration | Requires validator to whitelist full node | RaptorCast mode | Data Source |
|---|---|---|---|
| Normal | No | enable_client = true | Secondary RaptorCast |
| Prioritized secondary RaptorCast | Yes | enable_client = true | Secondary RaptorCast |
| Chunk forwarding | Yes | enable_client = false | Primary RaptorCast |
RaptorCast configurations for validators
Validators can toggle off their participation in secondary RaptorCast by settingenable_publisher = false.
Although turning secondary RaptorCast off will reduce bandwidth usage,
note that the bandwidth cost of secondary RaptorCast is relatively low; for example, even at
10,000 transactions per second, the expected usage will be about 6 MB per second (3 MB of
block data with 2x redundancy). Therefore, it is recommended to keep enable_publisher = true.

