Skip to main content

Module upgrade

Module upgrade 

Source
Expand description

The upgrade sub-protocol: proposing and voting on protocol version upgrades. Owns the wall clock and the window configuration so the pure consensus state machine never needs them.

Structs§

UpgradeProtocol

Constants§

DECIDE_BY_OFFSET
Views after the upgrade proposal by which a carrying leaf must decide. The certificate forms within a view of the proposal and each following leader re-attaches it, so this is the number of leader turns allowed.
FINISH_OFFSET
Views after the upgrade proposal at which the new version takes effect. The gap past DECIDE_BY_OFFSET is margin for nodes to decide the carrier before their own UpgradeLock flips the wire and header format.

Functions§

expected_upgrade_data 🔒
The UpgradeProposalData2 every honest node expects for an upgrade proposed at view in epoch. Voters require full equality, so a leader cannot pick rogue offsets (e.g. a new_version_first_view so close that the wire format would flip before the decided certificate propagates) or an epoch other than the voter’s own.
in_window 🔒
unix_time 🔒