Documentation ¶
Overview ¶
Package node contains the main executable for go-spacemesh node
Index ¶
- Constants
- func GetCommand() *cobra.Command
- func LoadConfig(cfg *config.Config, preset string, src io.Reader) error
- func WithErrorUnused() viper.DecoderConfigOption
- func WithIgnoreUntagged() viper.DecoderConfigOption
- func WithZeroFields() viper.DecoderConfigOption
- type App
- func (app *App) Cleanup(ctx context.Context)
- func (app *App) Host() *p2p.Host
- func (app *App) Initialize() error
- func (app *App) LoadIdentities() error
- func (app *App) Lock() error
- func (app *App) NewIdentity() error
- func (app *App) SetLogLevel(name, loglevel string) error
- func (app *App) Start(ctx context.Context) error
- func (app *App) Started() <-chan struct{}
- func (app *App) Unlock()
- type Option
- type TestApp
Constants ¶
const ( ClockLogger = "clock" P2PLogger = "p2p" PostLogger = "post" PostServiceLogger = "postService" PostInfoServiceLogger = "postInfoService" StateDbLogger = "stateDb" ApiStateDBLogger = "apiStateDB" BeaconLogger = "beacon" CachedDBLogger = "cachedDB" PoetDbLogger = "poetDb" TrtlLogger = "trtl" ATXHandlerLogger = "atxHandler" ATXBuilderLogger = "atxBuilder" MeshLogger = "mesh" SyncLogger = "sync" HareOracleLogger = "hareOracle" HareLogger = "hare" BlockCertLogger = "blockCert" BlockGenLogger = "blockGenerator" BlockHandlerLogger = "blockHandler" TxHandlerLogger = "txHandler" ProposalStoreLogger = "proposalStore" ProposalBuilderLogger = "proposalBuilder" ProposalListenerLogger = "proposalListener" NipostBuilderLogger = "nipostBuilder" NipostValidatorLogger = "nipostValidator" Fetcher = "fetcher" TimeSyncLogger = "timesync" VMLogger = "vm" GRPCLogger = "grpc" ConStateLogger = "conState" ExecutorLogger = "executor" MalfeasanceLogger = "malfeasance" BootstrapLogger = "bootstrap" )
Logger names.
Variables ¶
This section is empty.
Functions ¶
func GetCommand ¶
func LoadConfig ¶ added in v1.7.7
LoadConfig loads config and preset (if provided) into the provided config. It first loads the preset and then overrides it with values from the config file.
func WithErrorUnused ¶ added in v1.5.0
func WithErrorUnused() viper.DecoderConfigOption
func WithIgnoreUntagged ¶ added in v1.4.0
func WithIgnoreUntagged() viper.DecoderConfigOption
func WithZeroFields ¶ added in v1.4.0
func WithZeroFields() viper.DecoderConfigOption
Types ¶
type App ¶
App is the cli app singleton.
func (*App) Initialize ¶
Initialize parses and validates the node configuration and sets up logging.
func (*App) LoadIdentities ¶ added in v1.4.0
LoadIdentities loads all existing identities from the config directory.
func (*App) Lock ¶
Lock locks the app for exclusive use. It returns an error if the app is already locked.
func (*App) NewIdentity ¶ added in v1.4.0
NewIdentity creates a new identity, saves it to `keyDir/supervisedIDKeyFileName` in the config directory and initializes app.signers with that identity.
func (*App) SetLogLevel ¶
SetLogLevel updates the log level of an existing logger.
type Option ¶
type Option func(app *App)
Option to modify an App instance.
func WithConfig ¶
WithConfig overwrites default App config.