nodekeeper

package
v0.6.2 Latest Latest
Warning

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

Go to latest
Published: Nov 1, 2018 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewNodeKeeper added in v0.5.0

func NewNodeKeeper(origin *core.Node) network.NodeKeeper

NewNodeKeeper create new NodeKeeper

func NewNodeNetwork added in v0.6.2

func NewNodeNetwork(configuration configuration.Configuration) (core.NodeNetwork, error)

NewNodeNetwork create active node component

Types

type UnsyncList added in v0.6.0

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

func NewUnsyncHolder added in v0.6.0

func NewUnsyncHolder(pulse core.PulseNumber, unsync []*core.Node) *UnsyncList

NewUnsyncHolder create new object to hold data for consensus

func (*UnsyncList) AddUnsyncHash added in v0.6.0

func (u *UnsyncList) AddUnsyncHash(ref core.RecordRef, hash []*network.NodeUnsyncHash)

AddUnsyncHash add unsync hash for remote ref

func (*UnsyncList) AddUnsyncList added in v0.6.0

func (u *UnsyncList) AddUnsyncList(ref core.RecordRef, unsync []*core.Node)

AddUnsyncList add unsync list for remote ref

func (*UnsyncList) GetHash added in v0.6.0

func (u *UnsyncList) GetHash(blockTimeout time.Duration) ([]*network.NodeUnsyncHash, error)

GetHash get hash of unsync lists for each node of consensus. If hash is not calculated yet, then this call blocks until the hash is calculated with SetHash() call

func (*UnsyncList) GetPulse added in v0.6.0

func (u *UnsyncList) GetPulse() core.PulseNumber

GetPulse returns actual pulse for current consensus process.

func (*UnsyncList) GetUnsync added in v0.6.0

func (u *UnsyncList) GetUnsync() []*core.Node

GetUnsync returns list of local unsync nodes. This list is created

func (*UnsyncList) GetUnsyncHash added in v0.6.0

func (u *UnsyncList) GetUnsyncHash(ref core.RecordRef) ([]*network.NodeUnsyncHash, bool)

GetUnsyncHash get unsync hash for remote ref

func (*UnsyncList) GetUnsyncList added in v0.6.0

func (u *UnsyncList) GetUnsyncList(ref core.RecordRef) ([]*core.Node, bool)

GetUnsyncList get unsync list for remote ref

func (*UnsyncList) SetHash added in v0.6.0

func (u *UnsyncList) SetHash(hash []*network.NodeUnsyncHash)

SetHash sets hash of unsync lists for each node of consensus.

Jump to

Keyboard shortcuts

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