@@ -43,15 +43,17 @@ type State interface {
4343// However, since all blocks are certified upon insertion, they are immediately processable by other components.
4444type FollowerState interface {
4545 State
46+
4647 // ExtendCertified introduces the block with the given ID into the persistent
47- // protocol state without modifying the current finalized state. It allows
48- // us to execute fork-aware queries against ambiguous protocol state, while
49- // still checking that the given block is a valid extension of the protocol state.
50- // Caller must pass a QC for candidate block to prove that candidate block
51- // has been certified, and it's safe to add it to the protocol state.
52- // QC cannot be nil and must certify candidate block (candidate.View == qc.View && candidate.BlockID == qc.BlockID)
53- // The `candidate` block and its QC _must be valid_ (otherwise, the state will be corrupted).
54- // Unlike ParticipantState, if the input block is orphaned, it is inserted without error, so long as it is otherwise valid.
48+ // protocol state without modifying the current finalized state. It allows us
49+ // to execute fork-aware queries against the known protocol state. The caller
50+ // must pass a QC for candidate block to prove that the candidate block has
51+ // been certified, and it's safe to add it to the protocol state. The QC
52+ // cannot be nil and must certify candidate block:
53+ // candidate.View == qc.View && candidate.BlockID == qc.BlockID
54+ // The `candidate` block and its QC _must be valid_ (otherwise, the state will
55+ // be corrupted). ExtendCertified inserts any given block, as long as its
56+ // parent is already in the protocol state. Also orphaned blocks are excepted.
5557 // No errors are expected during normal operations.
5658 ExtendCertified (ctx context.Context , candidate * flow.Block , qc * flow.QuorumCertificate ) error
5759
@@ -69,6 +71,7 @@ type FollowerState interface {
6971// All blocks are validated in full, including payload validation, prior to insertion. Only valid blocks are inserted.
7072type ParticipantState interface {
7173 FollowerState
74+
7275 // Extend introduces the block with the given ID into the persistent
7376 // protocol state without modifying the current finalized state. It allows
7477 // us to execute fork-aware queries against ambiguous protocol state, while
0 commit comments