coldstuff

package
v0.14.9-error-printing Latest Latest
Warning

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

Go to latest
Published: Mar 12, 2021 License: AGPL-3.0 Imports: 15 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ColdStuff

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

ColdStuff implements coldstuff.

func New

func New(
	log zerolog.Logger,
	state protocol.State,
	me module.Local,
	comms Communicator,
	builder module.Builder,
	finalizer module.Finalizer,
	memberFilter flow.IdentityFilter,
	interval time.Duration,
	timeout time.Duration,
	head func() (*flow.Header, error),
) (*ColdStuff, error)

func (*ColdStuff) Done

func (e *ColdStuff) Done() <-chan struct{}

func (*ColdStuff) Ready

func (e *ColdStuff) Ready() <-chan struct{}

func (*ColdStuff) SubmitCommit

func (e *ColdStuff) SubmitCommit(commit *model.Commit)

func (*ColdStuff) SubmitProposal

func (e *ColdStuff) SubmitProposal(proposal *flow.Header, parentView uint64)

func (*ColdStuff) SubmitVote

func (e *ColdStuff) SubmitVote(originID, blockID flow.Identifier, view uint64, sigData []byte)

type Communicator

type Communicator interface {
	hotstuff.Communicator

	BroadcastCommit(commit *model.Commit) error
}

Communicator is the interface for sending messages to other nodes within a ColdStuff consensus.

NOTE: It re-uses as much of the HotStuff interface and models as possible to simplify swapping between the two.

type Follower

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

func NewFollower

func NewFollower(log zerolog.Logger, state protocol.MutableState, me module.Local) *Follower

func (*Follower) Done

func (f *Follower) Done() <-chan struct{}

func (*Follower) Ready

func (f *Follower) Ready() <-chan struct{}

func (*Follower) SubmitProposal

func (f *Follower) SubmitProposal(proposal *flow.Header, parentView uint64)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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