Documentation ¶
Overview ¶
Package eth implements the Ethereum protocol.
Index ¶
- func RemoveContents(dirname string) error
- type Config
- type Ethereum
- func (s *Ethereum) APIs() []rpc.API
- func (s *Ethereum) AddPeer(ctx context.Context, req *remote.AddPeerRequest) (*remote.AddPeerReply, error)
- func (s *Ethereum) BlockIO() (services.FullBlockReader, *blockio.BlockWriter)
- func (s *Ethereum) ChainConfig() *chain.Config
- func (s *Ethereum) ChainDB() kv.RwDB
- func (s *Ethereum) ChainKV() kv.RwDB
- func (s *Ethereum) DataDir() string
- func (s *Ethereum) Etherbase() (eb libcommon.Address, err error)
- func (s *Ethereum) ExecutionModule() *eth1.EthereumExecutionModule
- func (s *Ethereum) Init(stack *node.Node, config *ethconfig.Config, chainConfig *chain.Config) error
- func (s *Ethereum) IsMining() bool
- func (s *Ethereum) NetPeerCount() (uint64, error)
- func (s *Ethereum) NetVersion() (uint64, error)
- func (s *Ethereum) NodesInfo(limit int) (*remote.NodesInfoReply, error)
- func (s *Ethereum) Notifications() *shards.Notifications
- func (s *Ethereum) Peers(ctx context.Context) (*remote.PeersReply, error)
- func (s *Ethereum) PipelineStagedSync() *stagedsync.Sync
- func (s *Ethereum) Protocols() []p2p.Protocol
- func (s *Ethereum) Sentinel() rpcsentinel.SentinelClient
- func (s *Ethereum) SentryControlServer() *sentry_multi_client.MultiClient
- func (s *Ethereum) SentryCtx() context.Context
- func (s *Ethereum) StagedSync() *stagedsync.Sync
- func (s *Ethereum) Start() error
- func (s *Ethereum) StartMining(ctx context.Context, db kv.RwDB, stateDiffClient *direct.StateDiffClientDirect, ...) error
- func (s *Ethereum) Stop() error
- func (s *Ethereum) TxpoolServer() txpoolproto.TxpoolServer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RemoveContents ¶
RemoveContents is like os.RemoveAll, but preserve dir itself
Types ¶
type Config ¶
Config contains the configuration options of the ETH protocol. Deprecated: use ethconfig.Config instead.
type Ethereum ¶
type Ethereum struct {
// contains filtered or unexported fields
}
Ethereum implements the Ethereum full node service.
func New ¶
func New(ctx context.Context, stack *node.Node, config *ethconfig.Config, logger log.Logger) (*Ethereum, error)
New creates a new Ethereum object (including the initialisation of the common Ethereum object)
func (*Ethereum) AddPeer ¶
func (s *Ethereum) AddPeer(ctx context.Context, req *remote.AddPeerRequest) (*remote.AddPeerReply, error)
func (*Ethereum) BlockIO ¶
func (s *Ethereum) BlockIO() (services.FullBlockReader, *blockio.BlockWriter)
func (*Ethereum) ChainConfig ¶
func (*Ethereum) ExecutionModule ¶
func (s *Ethereum) ExecutionModule() *eth1.EthereumExecutionModule
func (*Ethereum) NetPeerCount ¶
func (*Ethereum) NetVersion ¶
func (*Ethereum) NodesInfo ¶
func (s *Ethereum) NodesInfo(limit int) (*remote.NodesInfoReply, error)
func (*Ethereum) Notifications ¶
func (s *Ethereum) Notifications() *shards.Notifications
func (*Ethereum) PipelineStagedSync ¶
func (s *Ethereum) PipelineStagedSync() *stagedsync.Sync
func (*Ethereum) Protocols ¶
Protocols returns all the currently configured network protocols to start.
func (*Ethereum) Sentinel ¶
func (s *Ethereum) Sentinel() rpcsentinel.SentinelClient
func (*Ethereum) SentryControlServer ¶
func (s *Ethereum) SentryControlServer() *sentry_multi_client.MultiClient
func (*Ethereum) StagedSync ¶
func (s *Ethereum) StagedSync() *stagedsync.Sync
func (*Ethereum) Start ¶
Start implements node.Lifecycle, starting all internal goroutines needed by the Ethereum protocol implementation.
func (*Ethereum) StartMining ¶
func (s *Ethereum) StartMining(ctx context.Context, db kv.RwDB, stateDiffClient *direct.StateDiffClientDirect, mining *stagedsync.Sync, miner stagedsync.MiningState, gasPrice *uint256.Int, quitCh chan struct{}, heimdallStore heimdall.Store, tmpDir string, logger log.Logger) error
StartMining starts the miner with the given number of CPU threads. If mining is already running, this method adjust the number of threads allowed to use and updates the minimum price required by the transaction pool.
func (*Ethereum) Stop ¶
Stop implements node.Service, terminating all internal goroutines used by the Ethereum protocol.
func (*Ethereum) TxpoolServer ¶
func (s *Ethereum) TxpoolServer() txpoolproto.TxpoolServer
Directories ¶
Path | Synopsis |
---|---|
Package ethconfig contains the configuration of the ETH and LES protocols.
|
Package ethconfig contains the configuration of the ETH and LES protocols. |
protocols
|
|
Package tracers is a manager for transaction tracing engines.
|
Package tracers is a manager for transaction tracing engines. |
js/internal/tracers
Package tracers contains the actual JavaScript tracer assets.
|
Package tracers contains the actual JavaScript tracer assets. |
native
Package native is a collection of tracers written in go.
|
Package native is a collection of tracers written in go. |