node

package
v1.15.3 Latest Latest
Warning

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

Go to latest
Published: Nov 4, 2026 License: BSD-3-Clause Imports: 81 Imported by: 13 modules, 23 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Node

type Node struct {
	Log          logging.Logger
	VMFactoryLog logging.Logger
	LogFactory   logging.Factory

	// This node's unique ID used when communicating with other nodes
	// (in consensus, for example)
	ID ids.NodeID

	StakingTLSSigner crypto.Signer
	StakingTLSCert   *staking.Certificate
	StakingSigner    bls.Signer

	// Storage for this node
	DB database.Database

	// dispatcher for events as they happen in consensus
	BlockAcceptorGroup  snow.AcceptorGroup
	TxAcceptorGroup     snow.AcceptorGroup
	VertexAcceptorGroup snow.AcceptorGroup

	// Net runs the networking stack
	Net network.Network

	// Handles HTTP API calls
	APIServer server.Server

	// This node's configuration
	Config *node.Config

	// Metrics Registerer
	MetricsGatherer        metrics.MultiGatherer
	MeterDBMetricsGatherer metrics.MultiGatherer

	VMAliaser ids.Aliaser
	VMManager *vms.Manager

	// VM endpoint registry
	VMRegistry registry.VMRegistry
	// contains filtered or unexported fields
}

Node is an instance of an Avalanche node.

func New added in v1.10.16

func New(
	config *node.Config,
	logFactory logging.Factory,
	logger logging.Logger,
) (*Node, error)

New returns an instance of Node

func (*Node) Dispatch

func (n *Node) Dispatch() error

Dispatch starts the node's servers. Returns when the node exits.

func (*Node) ExitCode added in v1.4.5

func (n *Node) ExitCode() int

func (*Node) Shutdown

func (n *Node) Shutdown(exitCode int)

Shutdown this node May be called multiple times All calls to shutdownOnce.Do block until the first call returns

Jump to

Keyboard shortcuts

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