initialsync

package
v0.3.10 Latest Latest
Warning

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

Go to latest
Published: Apr 7, 2020 License: GPL-3.0 Imports: 34 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	P2P           p2p.P2P
	DB            db.ReadOnlyDatabase
	Chain         blockchainService
	StateNotifier statefeed.Notifier
	BlockNotifier blockfeed.Notifier
}

Config to set up the initial sync service.

type Service added in v0.3.0

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

Service service.

func NewInitialSync

func NewInitialSync(cfg *Config) *Service

NewInitialSync configures the initial sync service responsible for bringing the node up to the latest head of the blockchain.

func (*Service) Resync added in v0.3.0

func (s *Service) Resync() error

Resync allows a node to start syncing again if it has fallen behind the current network head.

func (*Service) Start added in v0.3.0

func (s *Service) Start()

Start the initial sync service.

func (*Service) Status added in v0.3.0

func (s *Service) Status() error

Status of initial sync.

func (*Service) Stop added in v0.3.0

func (s *Service) Stop() error

Stop initial sync.

func (*Service) Syncing added in v0.3.0

func (s *Service) Syncing() bool

Syncing returns true if initial sync is still running.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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