Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update FLIP 204 #218

Merged
merged 1 commit into from
Nov 7, 2023
Merged
Changes from all commits
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
24 changes: 9 additions & 15 deletions protocol/20231003-service-account-specified-epoch-switchover.md.md
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@ pub fun getTargetEndTimeForEpoch(


### Implementation Plan
See also [ZenHub epic](https://github.com/onflow/flow-go/issues/4948).

#### Smart Contract

Expand Down Expand Up @@ -162,21 +163,14 @@ pub fun getTargetEndTimeForEpoch(
- Default value for deploying `FlowEpoch`

### Deployment Plan
#### Mainnet24 (Nov 8 2023)
1. Prepare patch which makes `EpochSetup` parsing forward-compatible (accept events with the extra `TargetEndTime` field, but discard it).
2. Rolling upgrade **all nodes** to this patch version.
3. Upgrade `FlowEpoch` contract.

As usual, deploy to Canary → Testnet → Mainnet

1. Upgrade `FlowEpoch`

<aside>
⚠️ Caution: First, ensure service event conversion logic is tolerant of additional fields (ignores additional fields)

</aside>

2. Upgrade Consensus Nodes

*Comment: Since we are modifying the EpochSetup model, this will likely require a spork.*


#### Mainnet25 (Q1-Q2 2024)
- Deploy `flow-go` version implementing FLIP 204.
- Since we have already upgraded the contract, no backward-compatibility in `flow-go` code is required (besides the patch above, which will remain on the `mainnet24` branch)

### Drawbacks

Expand Down Expand Up @@ -239,4 +233,4 @@ In **Option 1.1** and **2**, the timing of a particular epoch transition does no

#### Why do we set `TargetEndTime` rather than `TargetStartTime`?

The time information is specified in the `EpochSetup` event, which occurs partway through the current epoch. If we specified a `TargetStartTime`, then the PID Controller’s Process Variable would have an undefined value for part of the epoch, and the Cruise Control system would be unable to function. On Mainnet, this corresponds to about 90% of the duration of an epoch.
The time information is specified in the `EpochSetup` event, which occurs partway through the current epoch. If we specified a `TargetStartTime`, then the PID Controller’s Process Variable would have an undefined value for part of the epoch, and the Cruise Control system would be unable to function. On Mainnet, this corresponds to about 90% of the duration of an epoch.