{"modulePath":"github.com/MetaMask/tendermint","version":"v0.26.3","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package node\n\n## Functions\n\n```go\nfunc DefaultDBProvider(ctx *DBContext) (dbm.DB, error)\n```\nDefaultDBProvider returns a database using the DBBackend and DBDir specified in the ctx.Config.\n\n## Types\n\n```go\ntype DBContext struct {\n\tID     string\n\tConfig *cfg.Config\n}\n```\nDBContext specifies config information for loading a new DB.\n\n```go\ntype DBProvider func(*DBContext) (dbm.DB, error)\n```\nDBProvider takes a DBContext and returns an instantiated DB.\n\n```go\ntype GenesisDocProvider func() (*types.GenesisDoc, error)\n```\nGenesisDocProvider returns a GenesisDoc. It allows the GenesisDoc to be pulled from sources other than the filesystem, for instance from a distributed key-value store cluster.\n\n```go\nfunc DefaultGenesisDocProviderFunc(config *cfg.Config) GenesisDocProvider\n```\nDefaultGenesisDocProviderFunc returns a GenesisDocProvider that loads the GenesisDoc from the config.GenesisFile() on the filesystem.\n\n```go\ntype MetricsProvider func() (*cs.Metrics, *p2p.Metrics, *mempl.Metrics, *sm.Metrics)\n```\nMetricsProvider returns a consensus, p2p and mempool Metrics.\n\n```go\nfunc DefaultMetricsProvider(config *cfg.InstrumentationConfig) MetricsProvider\n```\nDefaultMetricsProvider returns Metrics build using Prometheus client library if Prometheus is enabled. Otherwise, it returns no-op Metrics.\n\n```go\ntype Node struct {\n\tcmn.BaseService\n\t// contains filtered or unexported fields\n}\n```\nNode is the highest level interface to a full Tendermint node. It includes all configuration information and running services.\n\n```go\nfunc DefaultNewNode(config *cfg.Config, logger log.Logger) (*Node, error)\n```\nDefaultNewNode returns a Tendermint node with default settings for the PrivValidator, ClientCreator, GenesisDoc, and DBProvider. It implements NodeProvider.\n\n```go\nfunc NewNode(config *cfg.Config,\n\tprivValidator types.PrivValidator,\n\tnodeKey *p2p.NodeKey,\n\tclientCreator proxy.ClientCreator,\n\tgenesisDocProvider GenesisDocProvider,\n\tdbProvider DBProvider,\n\tmetricsProvider MetricsProvider,\n\tlogger log.Logger) (*Node, error)\n```\nNewNode returns a new, ready to go, Tendermint Node.\n\n```go\nfunc (n *Node) BlockStore() *bc.BlockStore\n```\nBlockStore returns the Node's BlockStore.\n\n```go\nfunc (n *Node) ConfigureRPC()\n```\nConfigureRPC sets all variables in rpccore so they will serve rpc calls from this node\n\n```go\nfunc (n *Node) ConsensusReactor() *cs.ConsensusReactor\n```\nConsensusReactor returns the Node's ConsensusReactor.\n\n```go\nfunc (n *Node) ConsensusState() *cs.ConsensusState\n```\nConsensusState returns the Node's ConsensusState.\n\n```go\nfunc (n *Node) EventBus() *types.EventBus\n```\nEventBus returns the Node's EventBus.\n\n```go\nfunc (n *Node) EvidencePool() *evidence.EvidencePool\n```\nEvidencePool returns the Node's EvidencePool.\n\n```go\nfunc (n *Node) GenesisDoc() *types.GenesisDoc\n```\nGenesisDoc returns the Node's GenesisDoc.\n\n```go\nfunc (n *Node) IsListening() bool\n```\n\n```go\nfunc (n *Node) Listeners() []string\n```\n\n```go\nfunc (n *Node) MempoolReactor() *mempl.MempoolReactor\n```\nMempoolReactor returns the Node's MempoolReactor.\n\n```go\nfunc (n *Node) NodeInfo() p2p.NodeInfo\n```\nNodeInfo returns the Node's Info from the Switch.\n\n```go\nfunc (n *Node) OnStart() error\n```\nOnStart starts the Node. It implements cmn.Service.\n\n```go\nfunc (n *Node) OnStop()\n```\nOnStop stops the Node. It implements cmn.Service.\n\n```go\nfunc (n *Node) PrivValidator() types.PrivValidator\n```\nPrivValidator returns the Node's PrivValidator. XXX: for convenience only!\n\n```go\nfunc (n *Node) ProxyApp() proxy.AppConns\n```\nProxyApp returns the Node's AppConns, representing its connections to the ABCI application.\n\n```go\nfunc (n *Node) Switch() *p2p.Switch\n```\nSwitch returns the Node's Switch.\n\n```go\ntype NodeGreeting struct {\n\tNodeID\n\tVersion string\n\tChainID string\n\tMessage string\n\tTime    time.Time\n}\n```\n\n```go\ntype NodeID struct {\n\tName   string\n\tPubKey crypto.PubKey\n}\n```\n\n```go\ntype NodeProvider func(*cfg.Config, log.Logger) (*Node, error)\n```\nNodeProvider takes a config and a logger and returns a ready to go Node.\n\n```go\ntype PrivNodeID struct {\n\tNodeID\n\tPrivKey crypto.PrivKey\n}\n```\n\n```go\nfunc (pnid *PrivNodeID) SignGreeting() *SignedNodeGreeting\n```\n\n```go\ntype SignedNodeGreeting struct {\n\tNodeGreeting\n\tSignature []byte\n}\n```\n\n","path":"github.com/MetaMask/tendermint/node","name":"node","synopsis":"","isRedistributable":true}
