Skip to content

Commit

Permalink
Small update for upgrades.md (#1876)
Browse files Browse the repository at this point in the history
Updates for recent switch to `Versions` and small clarifications. 


---------

Co-authored-by: tbro <[email protected]>
Co-authored-by: Abdul Basit <[email protected]>
  • Loading branch information
3 people authored Aug 16, 2024
1 parent 4761a20 commit df26652
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions doc/upgrades.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Upgrades

Hotshot protocol supports upgrades through an Upgrade proposal mechanism. The Upgrade proposal is broadcast separately
from the `QuorumProposal`, typically several views in advance of its attachment. The goal is to ensure ample time for
from the `QuorumProposal`, typically several views before the upgrade is attempted. The goal is to ensure ample time for
nodes to receive and prepare for the upgrade process.

After enough votes have been collected on the `UpgradeProposal`, an `UpgradeCertificate` is formed. This is attached to
Expand Down Expand Up @@ -33,10 +33,10 @@ hash:
different proposals of the same version upgrade, ensuring nodes vote and execute the correct one. It consists of a
sequence of 32 bytes.

These are defined in [NodeType implementation](../types/src/v0/mod.rs) for the Types (`SeqTypes` in our case).
These are defined in [Versions implementation](../types/src/v0/mod.rs) for the Type (`SequencerVersions` in our case).

```rust
impl NodeType for SeqTypes {
impl Versions for SequencerVersions {
type Base = StaticVersion<0, 1>;
type Upgrade = StaticVersion<0, 2>;
const UPGRADE_HASH: [u8; 32] = [
Expand All @@ -53,7 +53,7 @@ parameters use Unix timestamps for the same purpose.

To simplify configuration, these parameters are fetched from the genesis TOML file and set in the Hotshot config. The
TOML file can include either view-based parameters or time-based parameters, but not both. Furthermore, the start and
stop voting parameters for both time-based and view-based upgrades are optional. Start parameter is set 0 so that voting
stop voting parameters for both time-based and view-based upgrades are optional. If omitted, start parameter will be set to 0 so that voting
begins as soon as node is started while the stop parameter is set to a maximum value so that the nodes keep voting until
enough votes are collected.

Expand Down

0 comments on commit df26652

Please sign in to comment.