status

package
v1.17.6-rc4 Latest Latest
Warning

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

Go to latest
Published: Nov 6, 2023 License: BSD-3-Clause Imports: 9 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Reserve added in v1.17.0

type Reserve interface {
	ReserveSize() int
	StorageRadius() uint8
}

Reserve defines the reserve storage related information required.

type Service

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

Service is the status service.

func NewService

func NewService(
	logger log.Logger,
	streamer p2p.Streamer,
	topology topologyDriver,
	beeMode string,
	commitment postage.CommitmentGetter,
	reserve Reserve,
) *Service

NewService creates a new status service.

func (*Service) LocalSnapshot

func (s *Service) LocalSnapshot() (*Snapshot, error)

LocalSnapshot returns the current status snapshot of this node.

func (*Service) PeerSnapshot added in v1.15.0

func (s *Service) PeerSnapshot(ctx context.Context, peer swarm.Address) (*Snapshot, error)

PeerSnapshot sends request for status snapshot to the peer.

func (*Service) Protocol

func (s *Service) Protocol() p2p.ProtocolSpec

Protocol returns the protocol specification.

func (*Service) SetSync added in v1.17.0

func (s *Service) SetSync(sync SyncReporter)

type Snapshot

type Snapshot pb.Snapshot

Snapshot is the current snapshot of the system.

type SyncReporter added in v1.17.0

type SyncReporter interface {
	SyncRate() float64
}

SyncReporter defines the interface to report syncing rate.

Directories

Path Synopsis
internal
pb

Jump to

Keyboard shortcuts

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