Documentation ¶
Index ¶
Constants ¶
View Source
const DefaultWakeupInterval = 5 * time.Minute
DefaultWakeupInterval is the default value for the depth monitor wake-up interval.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Reserve ¶ added in v1.14.0
type Reserve interface { // Current size of the reserve. ComputeReserveSize(uint8) (uint64, error) // Capacity of the reserve that is configured. ReserveCapacity() uint64 }
Reserve interface defines the functionality required from the local storage of the node to report information about the reserve. The reserve storage is the storage pledged by the node to the network.
type ReserveReporter ¶
type ReserveReporter interface { // ReserveSize returns the current reserve size. ReserveSize() uint64 }
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
Service implements the depthmonitor service
func New ¶
func New( t Topology, syncer SyncReporter, reserve Reserve, bs postage.Storer, logger log.Logger, warmupTime time.Duration, wakeupInterval time.Duration, freshNode bool, ) *Service
New constructs a new depthmonitor service
func (*Service) IsFullySynced ¶ added in v1.9.0
type SyncReporter ¶
type SyncReporter interface { // Number of active historical syncing jobs. SyncRate() float64 }
SyncReporter interface needs to be implemented by the syncing component of the node (puller).
type Topology ¶
type Topology interface { topologyDriver.SetStorageRadiuser topologyDriver.PeersCounter }
Topology interface encapsulates the functionality required by the topology component of the node.
Click to show internal directories.
Click to hide internal directories.