Documentation ¶
Index ¶
- Constants
- func DatabaseLauncher(kern *Kernel) process.Launcher
- func DefaultProcessLaunchers(kern *Kernel, rpcConfig *rpc.RPCConfig, keysConfig *keys.KeysConfig) []process.Launcher
- func GRPCLauncher(kern *Kernel, conf *rpc.ServerConfig, keyConfig *keys.KeysConfig) process.Launcher
- func InfoLauncher(kern *Kernel, conf *rpc.ServerConfig) process.Launcher
- func MetricsLauncher(kern *Kernel, conf *rpc.MetricsConfig) process.Launcher
- func NoConsensusLauncher(kern *Kernel) process.Launcher
- func ProfileLauncher(kern *Kernel, conf *rpc.ServerConfig) process.Launcher
- func StartupLauncher(kern *Kernel) process.Launcher
- func TendermintLauncher(kern *Kernel) process.Launcher
- func Web3Launcher(kern *Kernel, conf *rpc.ServerConfig) process.Launcher
- type Kernel
- func (kern *Kernel) AddExecutionOptions(opts ...execution.Option)
- func (kern *Kernel) AddProcesses(pl ...process.Launcher)
- func (kern *Kernel) Boot() (err error)
- func (kern *Kernel) GRPCListenAddress() net.Addr
- func (kern *Kernel) GetNodeView() (*tendermint.NodeView, error)
- func (kern *Kernel) InfoListenAddress() net.Addr
- func (kern *Kernel) LoadDump(genesisDoc *genesis.GenesisDoc, restoreFile string, silent bool) (err error)
- func (kern *Kernel) LoadExecutionOptionsFromConfig(conf *execution.ExecutionConfig) error
- func (kern *Kernel) LoadKeysFromConfig(conf *keys.KeysConfig) (err error)
- func (kern *Kernel) LoadLoggerFromConfig(conf *logconfig.LoggingConfig) error
- func (kern *Kernel) LoadState(genesisDoc *genesis.GenesisDoc) (err error)
- func (kern *Kernel) LoadTendermintFromConfig(conf *config.BurrowConfig, privVal tmTypes.PrivValidator) (err error)
- func (kern *Kernel) MetricsListenAddress() net.Addr
- func (kern *Kernel) Panic(err error)
- func (kern *Kernel) PrivValidator(validator crypto.Address) (tmTypes.PrivValidator, error)
- func (kern *Kernel) SetKeyClient(client keys.KeyClient)
- func (kern *Kernel) SetKeyStore(store *keys.KeyStore)
- func (kern *Kernel) SetLogger(logger *logging.Logger)
- func (kern *Kernel) Shutdown(ctx context.Context) (err error)
- func (kern *Kernel) ShutdownAndExit()
- func (kern *Kernel) String() string
- func (kern *Kernel) WaitForShutdown()
Constants ¶
const ( CooldownTime = 1000 * time.Millisecond ServerShutdownTimeout = 5000 * time.Millisecond LoggingCallerDepth = 5 AccountsRingMutexCount = 100 BurrowDBName = "burrow_state" )
const ( ProfilingProcessName = "Profiling" DatabaseProcessName = "Database" NoConsensusProcessName = "NoConsensusExecution" TendermintProcessName = "Tendermint" StartupProcessName = "StartupAnnouncer" Web3ProcessName = "rpcConfig/web3" InfoProcessName = "rpcConfig/info" GRPCProcessName = "rpcConfig/GRPC" MetricsProcessName = "rpcConfig/metrics" )
Variables ¶
This section is empty.
Functions ¶
func DatabaseLauncher ¶ added in v0.25.0
func DefaultProcessLaunchers ¶ added in v0.25.0
func GRPCLauncher ¶ added in v0.25.0
func GRPCLauncher(kern *Kernel, conf *rpc.ServerConfig, keyConfig *keys.KeysConfig) process.Launcher
func InfoLauncher ¶ added in v0.25.0
func InfoLauncher(kern *Kernel, conf *rpc.ServerConfig) process.Launcher
func MetricsLauncher ¶ added in v0.25.0
func MetricsLauncher(kern *Kernel, conf *rpc.MetricsConfig) process.Launcher
func NoConsensusLauncher ¶ added in v0.25.0
Run a single uncoordinated local state
func ProfileLauncher ¶ added in v0.25.0
func ProfileLauncher(kern *Kernel, conf *rpc.ServerConfig) process.Launcher
func StartupLauncher ¶ added in v0.25.0
func TendermintLauncher ¶ added in v0.25.0
func Web3Launcher ¶ added in v0.29.0
func Web3Launcher(kern *Kernel, conf *rpc.ServerConfig) process.Launcher
Types ¶
type Kernel ¶ added in v0.18.0
type Kernel struct { // Expose these public-facing interfaces to allow programmatic extension of the Kernel by other projects Emitter *event.Emitter Service *rpc.Service EthService *rpc.EthService Launchers []process.Launcher State *state.State Blockchain *bcm.Blockchain Node *tendermint.Node Transactor *execution.Transactor RunID simpleuuid.UUID // Time-based UUID randomly generated each time Burrow is started Logger *logging.Logger // contains filtered or unexported fields }
Kernel is the root structure of Burrow
func LoadKernelFromConfig ¶ added in v0.25.0
func LoadKernelFromConfig(conf *config.BurrowConfig) (*Kernel, error)
LoadKernelFromConfig builds and returns a Kernel based solely on the supplied configuration
func (*Kernel) AddExecutionOptions ¶ added in v0.25.0
AddExecutionOptions extends our execution options
func (*Kernel) AddProcesses ¶ added in v0.25.0
AddProcesses extends the services that we launch at boot
func (*Kernel) GRPCListenAddress ¶ added in v0.25.0
func (*Kernel) GetNodeView ¶ added in v0.25.0
func (kern *Kernel) GetNodeView() (*tendermint.NodeView, error)
GetNodeView builds and returns a wrapper of our tendermint node
func (*Kernel) InfoListenAddress ¶ added in v0.25.0
func (*Kernel) LoadDump ¶ added in v0.25.0
func (kern *Kernel) LoadDump(genesisDoc *genesis.GenesisDoc, restoreFile string, silent bool) (err error)
LoadDump restores chain state from the given dump file
func (*Kernel) LoadExecutionOptionsFromConfig ¶ added in v0.25.0
func (kern *Kernel) LoadExecutionOptionsFromConfig(conf *execution.ExecutionConfig) error
LoadExecutionOptionsFromConfig builds the execution options for the kernel
func (*Kernel) LoadKeysFromConfig ¶ added in v0.25.0
func (kern *Kernel) LoadKeysFromConfig(conf *keys.KeysConfig) (err error)
LoadKeysFromConfig sets the keyClient & keyStore based on the given config
func (*Kernel) LoadLoggerFromConfig ¶ added in v0.25.0
func (kern *Kernel) LoadLoggerFromConfig(conf *logconfig.LoggingConfig) error
LoadLoggerFromConfig adds a logging configuration to the kernel
func (*Kernel) LoadState ¶ added in v0.25.0
func (kern *Kernel) LoadState(genesisDoc *genesis.GenesisDoc) (err error)
LoadState starts from scratch or previous chain
func (*Kernel) LoadTendermintFromConfig ¶ added in v0.25.0
func (kern *Kernel) LoadTendermintFromConfig(conf *config.BurrowConfig, privVal tmTypes.PrivValidator) (err error)
LoadTendermintFromConfig loads our consensus engine into the kernel
func (*Kernel) MetricsListenAddress ¶ added in v0.25.0
func (*Kernel) PrivValidator ¶ added in v0.25.0
Generates an in-memory Tendermint PrivValidator (suitable for passing to LoadTendermintFromConfig)
func (*Kernel) SetKeyClient ¶ added in v0.25.0
SetKeyClient explicitly sets the key client
func (*Kernel) SetKeyStore ¶ added in v0.25.0
SetKeyStore explicitly sets the key store
func (*Kernel) SetLogger ¶ added in v0.25.0
SetLogger initializes the kernel with the provided logger
func (*Kernel) Shutdown ¶ added in v0.18.0
Shutdown stops the kernel allowing for a graceful shutdown of components in order
func (*Kernel) ShutdownAndExit ¶ added in v0.25.0
func (kern *Kernel) ShutdownAndExit()
func (*Kernel) WaitForShutdown ¶ added in v0.18.0
func (kern *Kernel) WaitForShutdown()
Wait for a graceful shutdown