Documentation
      ¶
    
    
  
    
  
    Index ¶
- Constants
 - Variables
 - type Admin
 - func (p *Admin) GetVMConfig(_ *http.Request, _ *struct{}, reply *client.ConfigReply) error
 - func (p *Admin) LockProfile(_ *http.Request, _ *struct{}, _ *api.EmptyReply) error
 - func (p *Admin) MemoryProfile(_ *http.Request, _ *struct{}, _ *api.EmptyReply) error
 - func (p *Admin) SetLogLevel(_ *http.Request, args *client.SetLogLevelArgs, reply *api.EmptyReply) error
 - func (p *Admin) StartCPUProfiler(_ *http.Request, _ *struct{}, _ *api.EmptyReply) error
 - func (p *Admin) StopCPUProfiler(r *http.Request, _ *struct{}, _ *api.EmptyReply) error
 
- type EthPushGossiper
 - type GossipEthTx
 - type GossipEthTxMarshaller
 - type GossipEthTxPool
 - func (g *GossipEthTxPool) Add(tx *GossipEthTx) error
 - func (g *GossipEthTxPool) GetFilter() ([]byte, []byte)
 - func (g *GossipEthTxPool) Has(txID ids.ID) bool
 - func (g *GossipEthTxPool) IsSubscribed() bool
 - func (g *GossipEthTxPool) Iterate(f func(tx *GossipEthTx) bool)
 - func (g *GossipEthTxPool) Subscribe(ctx context.Context)
 
- type LeafHandlers
 - type LeafRequestTypeConfig
 - type VM
 - func (vm *VM) ChainConfig() *params.ChainConfig
 - func (vm *VM) Config() config.Config
 - func (vm *VM) CreateHandlers(context.Context) (map[string]http.Handler, error)
 - func (vm *VM) Ethereum() *eth.Ethereum
 - func (vm *VM) GetAcceptedBlock(ctx context.Context, blkID ids.ID) (snowman.Block, error)
 - func (vm *VM) GetBlockIDAtHeight(_ context.Context, height uint64) (ids.ID, error)
 - func (vm *VM) GetExtendedBlock(ctx context.Context, blkID ids.ID) (extension.ExtendedBlock, error)
 - func (vm *VM) HealthCheck(context.Context) (interface{}, error)
 - func (vm *VM) Initialize(_ context.Context, chainCtx *snow.Context, db database.Database, ...) error
 - func (vm *VM) LastAcceptedExtendedBlock() extension.ExtendedBlock
 - func (vm *VM) MetricRegistry() *prometheus.Registry
 - func (vm *VM) NewBlockBuilder(extraMempool extension.BuilderMempool) *blockBuilder
 - func (*VM) NewHTTPHandler(context.Context) (http.Handler, error)
 - func (vm *VM) ParseEthBlock(b []byte) (*types.Block, error)
 - func (vm *VM) PutLastAcceptedID(ID ids.ID) error
 - func (vm *VM) ReadLastAccepted() (common.Hash, uint64, error)
 - func (vm *VM) SetExtensionConfig(config *extension.Config) error
 - func (vm *VM) SetPreference(ctx context.Context, blkID ids.ID) error
 - func (vm *VM) SetState(_ context.Context, state snow.State) error
 - func (vm *VM) Shutdown(context.Context) error
 - func (vm *VM) SyncerClient() vmsync.Client
 - func (vm *VM) Validators() *p2p.Validators
 - func (vm *VM) Version(context.Context) (string, error)
 - func (vm *VM) VersionDB() *versiondb.Database
 - func (vm *VM) WaitForEvent(ctx context.Context) (commonEng.Message, error)
 
Constants ¶
const MinBlockBuildingRetryDelay = 500 * time.Millisecond
    Minimum amount of time to wait after building a block before attempting to build a block a second time without changing the contents of the mempool.
Variables ¶
var ( // GitCommit is set by the build script GitCommit string // Version is the version of Coreth Version string = "v0.15.4" )
Functions ¶
This section is empty.
Types ¶
type Admin ¶ added in v0.7.4
type Admin struct {
	// contains filtered or unexported fields
}
    Admin is the API service for admin API calls
func NewAdminService ¶ added in v0.7.4
func (*Admin) GetVMConfig ¶ added in v0.8.9
func (*Admin) LockProfile ¶ added in v0.7.4
LockProfile runs a mutex profile writing to the specified file
func (*Admin) MemoryProfile ¶ added in v0.7.4
MemoryProfile runs a memory profile writing to the specified file
func (*Admin) SetLogLevel ¶ added in v0.7.4
func (p *Admin) SetLogLevel(_ *http.Request, args *client.SetLogLevelArgs, reply *api.EmptyReply) error
func (*Admin) StartCPUProfiler ¶ added in v0.7.4
StartCPUProfiler starts a cpu profile writing to the specified file
func (*Admin) StopCPUProfiler ¶ added in v0.7.4
StopCPUProfiler stops the cpu profile
type EthPushGossiper ¶ added in v0.13.1
type EthPushGossiper struct {
	// contains filtered or unexported fields
}
    EthPushGossiper is used by the ETH backend to push transactions issued over the RPC and added to the mempool to peers.
func (*EthPushGossiper) Add ¶ added in v0.13.1
func (e *EthPushGossiper) Add(tx *types.Transaction)
type GossipEthTx ¶ added in v0.12.5
type GossipEthTx struct {
	Tx *types.Transaction
}
    func (*GossipEthTx) GossipID ¶ added in v0.12.10
func (tx *GossipEthTx) GossipID() ids.ID
type GossipEthTxMarshaller ¶ added in v0.12.10
type GossipEthTxMarshaller struct{}
    func (GossipEthTxMarshaller) MarshalGossip ¶ added in v0.12.10
func (g GossipEthTxMarshaller) MarshalGossip(tx *GossipEthTx) ([]byte, error)
func (GossipEthTxMarshaller) UnmarshalGossip ¶ added in v0.12.10
func (g GossipEthTxMarshaller) UnmarshalGossip(bytes []byte) (*GossipEthTx, error)
type GossipEthTxPool ¶ added in v0.12.5
type GossipEthTxPool struct {
	// contains filtered or unexported fields
}
    func NewGossipEthTxPool ¶ added in v0.12.5
func NewGossipEthTxPool(mempool *txpool.TxPool, registerer prometheus.Registerer) (*GossipEthTxPool, error)
func (*GossipEthTxPool) Add ¶ added in v0.12.5
func (g *GossipEthTxPool) Add(tx *GossipEthTx) error
Add enqueues the transaction to the mempool. Subscribe should be called to receive an event if tx is actually added to the mempool or not.
func (*GossipEthTxPool) GetFilter ¶ added in v0.12.5
func (g *GossipEthTxPool) GetFilter() ([]byte, []byte)
func (*GossipEthTxPool) Has ¶ added in v0.13.1
func (g *GossipEthTxPool) Has(txID ids.ID) bool
Has should just return whether or not the [txID] is still in the mempool, not whether it is in the mempool AND pending.
func (*GossipEthTxPool) IsSubscribed ¶ added in v0.13.3
func (g *GossipEthTxPool) IsSubscribed() bool
IsSubscribed returns whether or not the gossip subscription is active.
func (*GossipEthTxPool) Iterate ¶ added in v0.12.5
func (g *GossipEthTxPool) Iterate(f func(tx *GossipEthTx) bool)
func (*GossipEthTxPool) Subscribe ¶ added in v0.12.5
func (g *GossipEthTxPool) Subscribe(ctx context.Context)
type LeafHandlers ¶ added in v0.15.2
type LeafHandlers map[message.NodeType]syncHandlers.LeafRequestHandler
type LeafRequestTypeConfig ¶ added in v0.15.2
type VM ¶
type VM struct {
	// *chain.State helps to implement the VM interface by wrapping blocks
	// with an efficient caching layer.
	*chain.State
	network.Network
	IsPlugin bool
	// State sync server and client
	vmsync.Server
	vmsync.Client
	// contains filtered or unexported fields
}
    VM implements the snowman.ChainVM interface
func (*VM) ChainConfig ¶ added in v0.15.3
func (vm *VM) ChainConfig() *params.ChainConfig
ChainConfig returns the chain config for the VM Even though this is available through Blockchain().Config(), ChainConfig() here will be available before the blockchain is initialized.
func (*VM) CreateHandlers ¶
CreateHandlers makes new http handlers that can handle API calls
func (*VM) GetAcceptedBlock ¶ added in v0.13.7
GetAcceptedBlock attempts to retrieve block [blkID] from the VM. This method only returns accepted blocks.
func (*VM) GetBlockIDAtHeight ¶ added in v0.8.5
GetBlockIDAtHeight returns the canonical block at [height]. Note: the engine assumes that if a block is not found at [height], then [database.ErrNotFound] will be returned. This indicates that the VM has state synced and does not have all historical blocks available.
func (*VM) GetExtendedBlock ¶ added in v0.15.2
func (*VM) HealthCheck ¶ added in v0.3.25
Health returns nil if this chain is healthy. Also returns details, which should be one of: string, []byte, map[string]string
func (*VM) Initialize ¶
func (vm *VM) Initialize( _ context.Context, chainCtx *snow.Context, db database.Database, genesisBytes []byte, _ []byte, configBytes []byte, _ []*commonEng.Fx, appSender commonEng.AppSender, ) error
Initialize implements the snowman.ChainVM interface
func (*VM) LastAcceptedExtendedBlock ¶ added in v0.15.2
func (vm *VM) LastAcceptedExtendedBlock() extension.ExtendedBlock
func (*VM) MetricRegistry ¶ added in v0.15.3
func (vm *VM) MetricRegistry() *prometheus.Registry
func (*VM) NewBlockBuilder ¶ added in v0.7.0
func (vm *VM) NewBlockBuilder(extraMempool extension.BuilderMempool) *blockBuilder
NewBlockBuilder creates a new block builder. extraMempool is an optional mempool (can be nil) that can be used to add transactions to the block builder, in addition to the txPool.
func (*VM) NewHTTPHandler ¶ added in v0.15.3
func (*VM) ParseEthBlock ¶ added in v0.8.11
func (*VM) ReadLastAccepted ¶ added in v0.15.3
readLastAccepted reads the last accepted hash from [acceptedBlockDB] and returns the last accepted block hash and height by reading directly from [vm.chaindb] instead of relying on chain. Note: assumes [vm.chaindb] and [vm.genesisHash] have been initialized.
func (*VM) SetExtensionConfig ¶ added in v0.15.2
func (*VM) SetPreference ¶
SetPreference sets what the current tail of the chain is
func (*VM) SyncerClient ¶ added in v0.15.3
func (*VM) Validators ¶ added in v0.15.3
func (vm *VM) Validators() *p2p.Validators
      
      Source Files
      ¶
    
  
      
      Directories
      ¶
    
    | Path | Synopsis | 
|---|---|
| 
       upgrade
        | 
      |
| 
         
          
            acp176
            
            
          
           
      ACP176 implements the fee logic specified here: https://github.com/avalanche-foundation/ACPs/blob/main/ACPs/176-dynamic-evm-gas-limit-and-price-discovery-updates/README.md 
         | 
      ACP176 implements the fee logic specified here: https://github.com/avalanche-foundation/ACPs/blob/main/ACPs/176-dynamic-evm-gas-limit-and-price-discovery-updates/README.md | 
| 
         
          
            ap0
            
            
          
           
      AP0 defines constants used during the initial network launch. 
         | 
      AP0 defines constants used during the initial network launch. | 
| 
         
          
            ap1
            
            
          
           
      AP1 defines constants used after the Apricot Phase 1 upgrade. 
         | 
      AP1 defines constants used after the Apricot Phase 1 upgrade. | 
| 
         
          
            ap3
            
            
          
           
      AP3 defines the dynamic fee window used after the Apricot Phase 3 upgrade. 
         | 
      AP3 defines the dynamic fee window used after the Apricot Phase 3 upgrade. | 
| 
         
          
            ap4
            
            
          
           
      AP4 implements the block gas cost logic activated by the Apricot Phase 4 upgrade. 
         | 
      AP4 implements the block gas cost logic activated by the Apricot Phase 4 upgrade. | 
| 
         
          
            ap5
            
            
          
           
      AP5 defines constants used after the Apricot Phase 5 upgrade. 
         | 
      AP5 defines constants used after the Apricot Phase 5 upgrade. | 
| 
         
          
            cortina
            
            
          
           
      Cortina defines constants used after the Cortina upgrade. 
         | 
      Cortina defines constants used after the Cortina upgrade. | 
| 
         
          
            etna
            
            
          
           
      Etna defines constants used after the Etna upgrade. 
         | 
      Etna defines constants used after the Etna upgrade. |