Documentation
¶
Overview ¶
Implement the wrapping calls to the wrapped engines. Forwards the RPC call to op-geth server while directly calling the cosmos sdk engine. See https://ethereum.github.io/execution-apis/api-documentation/
types.go holds any additional required type definitions for the server implementations.
Index ¶
- func EngineForkStates(blockStore BlockStore, interceptorForkState eth.ForkchoiceState) (eth.ForkchoiceState, eth.ForkchoiceState)
- func GetCosmosAPI(mempoolNode MempoolNode, peptideRPC client.RPC, logger log.Logger) rpc.API
- func GetEngineAPI(interceptor Interceptor, ethPRC, peptideRPC client.RPC, logger log.Logger) []rpc.API
- func GetEthAPI(blockStore BlockStore, ethRPC, peptideRPC client.RPC, logger log.Logger) rpc.API
- func IsIBCBridgeTx(data hexutil.Bytes) bool
- type BlockStore
- type Hash
- type Interceptor
- type MempoolNode
- type PayloadStore
- type SendCosmosTxResult
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EngineForkStates ¶
func EngineForkStates(blockStore BlockStore, interceptorForkState eth.ForkchoiceState) (eth.ForkchoiceState, eth.ForkchoiceState)
EngineForkStates takes in the interceptor fork state and the blockstore and creates two states for abci and geth.
func GetCosmosAPI ¶
func GetEngineAPI ¶
func GetEngineAPI(interceptor Interceptor, ethPRC, peptideRPC client.RPC, logger log.Logger) []rpc.API
TODO(jim): passed by lock.
func IsIBCBridgeTx ¶
IsIBCBridgeTx returns true if the transaction is a transaction sent to the IBCStandardBridge. tx is a hex encoded marshalled types.Transaction (op-geth/core/types/transaction.go)
Types ¶
type BlockStore ¶
type BlockStore interface {
GetCompositeBlock(common.Hash) eetypes.CompositeBlock
SaveCompositeBlock(eetypes.CompositeBlock)
}
BlockStore allows accessing/modifying/inspecting the compose blocks.
type Interceptor ¶
type Interceptor interface {
MempoolNode
BlockStore
PayloadStore
}
type MempoolNode ¶
type MempoolNode interface {
// HasMsgs returns true if the mempool has messages.
HasMsgs() bool
// GetMsgs returns all messages in the mempool.
GetMsgs() [][]byte
// ClearMsgs clears all messages from the mempool.
ClearMsgs()
// AddMsgToMempool adds a message to the mempool.
AddMsgToMempool(bz []byte)
}
MempoolNode allows accessing/modifying/inspecting the mempool.
type PayloadStore ¶
type PayloadStore interface {
GetCompositePayload(eth.PayloadID) eetypes.CompositePayload
SaveCompositePayload(eetypes.CompositePayload)
}
type SendCosmosTxResult ¶
type SendCosmosTxResult struct{}
TODO(jim): Ethereum JSON/RPC dictates responses should either return 0, 1 (response or error) or 2 (response and error). For now, we return 2 just to keep separated.