consensus

package
v0.6.1 Latest Latest
Warning

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

Go to latest
Published: Oct 23, 2018 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewInsolarConsensus

func NewInsolarConsensus(handler hosthandler.HostHandler) consensus.Processor

NewInsolarConsensus creates new object to handle all consensus events

Types

type NetworkConsensus

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

NetworkConsensus binds all functionality related to consensus with the network layer

func (*NetworkConsensus) IsPartOfConsensus

func (ic *NetworkConsensus) IsPartOfConsensus() bool

IsPartOfConsensus returns whether we should perform all consensus interactions or not

func (*NetworkConsensus) ProcessPulse

func (ic *NetworkConsensus) ProcessPulse(ctx context.Context, pulse core.Pulse)

ProcessPulse is called when we get new pulse from pulsar. Should be called in goroutine

func (*NetworkConsensus) ReceiverHandler

func (ic *NetworkConsensus) ReceiverHandler() consensus.CommunicatorReceiver

ReceiverHandler return handler that is responsible to handle consensus network requests

func (*NetworkConsensus) SetNodeKeeper added in v0.6.1

func (ic *NetworkConsensus) SetNodeKeeper(keeper consensus.NodeKeeper)

SetNodeKeeper set NodeKeeper for the processor to integrate Processor with unsync -> sync -> active pipeline

Jump to

Keyboard shortcuts

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