follow

package
v0.2.9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 30, 2026 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Overview

Package follow implements the `fxadmin follow` command, which waits for a pending configuration update to commit across all assemblers.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Handler

type Handler struct {
	// contains filtered or unexported fields
}

Handler executes the follow command. It carries the BCCSP used to build the channel config bundle when reading connection info from the config block.

func New

func New() *Handler

New returns a follow command handler.

func (*Handler) Run

func (h *Handler) Run(configPath, currentBlockPath, outputPath string, timeout time.Duration) error

Run implements `fxadmin follow`. It reads the assembler endpoints and current config sequence from the config block, then polls every assembler until each has committed the next config block (sequence current+1) or the timeout elapses, and prints a per-assembler summary. A config update changes at most one assembler, so the endpoints in the current block still reach the rest; assemblers that cannot be reached are reported as unreachable.

Once at least f+1 assemblers report the same next config block (f being the number of faulty parties the network tolerates), that block is trusted - f+1 matching copies guarantee at least one came from an honest assembler - and written to outputPath, ready to be the --current-block of the next reconfiguration. Blocks are matched by their header and data only, ignoring the per-assembler signature metadata. Run returns an error if no such agreement is reached before the timeout.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL