Documentation ¶
Index ¶
- Constants
- Variables
- func RegisterInterfaces(registry cdctypes.InterfaceRegistry)
- func RegisterMsgServiceServer(s grpc1.Server, srv MsgServiceServer)
- func ValidateExecutionBlockHash(executionBlockHash []byte) error
- type AccountKeeper
- type DistrKeeper
- type EVMEvent
- func (*EVMEvent) Descriptor() ([]byte, []int)
- func (m *EVMEvent) GetAddress() []byte
- func (m *EVMEvent) GetData() []byte
- func (m *EVMEvent) GetTopics() [][]byte
- func (m *EVMEvent) Marshal() (dAtA []byte, err error)
- func (m *EVMEvent) MarshalTo(dAtA []byte) (int, error)
- func (m *EVMEvent) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*EVMEvent) ProtoMessage()
- func (m *EVMEvent) Reset()
- func (m *EVMEvent) Size() (n int)
- func (m *EVMEvent) String() string
- func (l *EVMEvent) ToEthLog() (ethtypes.Log, error)
- func (m *EVMEvent) Unmarshal(dAtA []byte) error
- func (l *EVMEvent) Verify() error
- func (m *EVMEvent) XXX_DiscardUnknown()
- func (m *EVMEvent) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *EVMEvent) XXX_Merge(src proto.Message)
- func (m *EVMEvent) XXX_Size() int
- func (m *EVMEvent) XXX_Unmarshal(b []byte) error
- type EvmEventProcessor
- type EvmStakingKeeper
- type ExecutionPayloadResponse
- func (*ExecutionPayloadResponse) Descriptor() ([]byte, []int)
- func (m *ExecutionPayloadResponse) Marshal() (dAtA []byte, err error)
- func (m *ExecutionPayloadResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *ExecutionPayloadResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*ExecutionPayloadResponse) ProtoMessage()
- func (m *ExecutionPayloadResponse) Reset()
- func (m *ExecutionPayloadResponse) Size() (n int)
- func (m *ExecutionPayloadResponse) String() string
- func (m *ExecutionPayloadResponse) Unmarshal(dAtA []byte) error
- func (m *ExecutionPayloadResponse) XXX_DiscardUnknown()
- func (m *ExecutionPayloadResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ExecutionPayloadResponse) XXX_Merge(src proto.Message)
- func (m *ExecutionPayloadResponse) XXX_Size() int
- func (m *ExecutionPayloadResponse) XXX_Unmarshal(b []byte) error
- type GenesisState
- func (*GenesisState) Descriptor() ([]byte, []int)
- func (m *GenesisState) GetParams() Params
- func (m *GenesisState) Marshal() (dAtA []byte, err error)
- func (m *GenesisState) MarshalTo(dAtA []byte) (int, error)
- func (m *GenesisState) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*GenesisState) ProtoMessage()
- func (m *GenesisState) Reset()
- func (m *GenesisState) Size() (n int)
- func (m *GenesisState) String() string
- func (m *GenesisState) Unmarshal(dAtA []byte) error
- func (m *GenesisState) XXX_DiscardUnknown()
- func (m *GenesisState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *GenesisState) XXX_Merge(src proto.Message)
- func (m *GenesisState) XXX_Size() int
- func (m *GenesisState) XXX_Unmarshal(b []byte) error
- type MsgExecutionPayload
- func (*MsgExecutionPayload) Descriptor() ([]byte, []int)
- func (m *MsgExecutionPayload) GetAuthority() string
- func (m *MsgExecutionPayload) GetExecutionPayload() []byte
- func (m *MsgExecutionPayload) GetPrevPayloadEvents() []*EVMEvent
- func (m *MsgExecutionPayload) Marshal() (dAtA []byte, err error)
- func (m *MsgExecutionPayload) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgExecutionPayload) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgExecutionPayload) ProtoMessage()
- func (m *MsgExecutionPayload) Reset()
- func (m *MsgExecutionPayload) Size() (n int)
- func (m *MsgExecutionPayload) String() string
- func (m *MsgExecutionPayload) Unmarshal(dAtA []byte) error
- func (m *MsgExecutionPayload) XXX_DiscardUnknown()
- func (m *MsgExecutionPayload) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgExecutionPayload) XXX_Merge(src proto.Message)
- func (m *MsgExecutionPayload) XXX_Size() int
- func (m *MsgExecutionPayload) XXX_Unmarshal(b []byte) error
- type MsgServiceClient
- type MsgServiceServer
- type Params
- func (*Params) Descriptor() ([]byte, []int)
- func (m *Params) GetExecutionBlockHash() []byte
- func (m *Params) Marshal() (dAtA []byte, err error)
- func (m *Params) MarshalTo(dAtA []byte) (int, error)
- func (m *Params) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Params) ProtoMessage()
- func (m *Params) Reset()
- func (m *Params) Size() (n int)
- func (m *Params) String() string
- func (m *Params) Unmarshal(dAtA []byte) error
- func (m *Params) XXX_DiscardUnknown()
- func (m *Params) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Params) XXX_Merge(src proto.Message)
- func (m *Params) XXX_Size() int
- func (m *Params) XXX_Unmarshal(b []byte) error
- type UnimplementedMsgServiceServer
- type UpgradeKeeper
- type VoteExtensionProvider
Constants ¶
const ( EventTypeUpgradeFailure = "upgrade_failure" EventTypeUpdateUbiFailure = "update_ubi_failure" AttributeKeyStatusCode = "status_code" AttributeKeyBlockHeight = "block_height" AttributeKeyUpgradeName = "upgrade_name" AttributeKeyUpgradeHeight = "upgrade_height" AttributeKeyUpgradeInfo = "upgrade_info" AttributeKeyUbiPercentage = "ubi_percentage" )
evmstaking module event types.
const ( // ModuleName defines the module name. ModuleName = "evmengine" // StoreKey defines the primary module store key. StoreKey = ModuleName // MemStoreKey defines the in-memory store key. MemStoreKey = "mem_evmengine" )
Variables ¶
var ( ErrInvalidLengthGenesis = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowGenesis = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupGenesis = fmt.Errorf("proto: unexpected end of group") )
var ( ErrInvalidLengthParams = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowParams = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupParams = fmt.Errorf("proto: unexpected end of group") )
var ( ErrInvalidLengthTx = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowTx = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupTx = fmt.Errorf("proto: unexpected end of group") )
var (
ParamsKey = collections.NewPrefix(0)
)
KVStore key prefixes.
var (
SoftwareUpgradeEvent = mustGetEvent(upgradeEntrypointABI, "SoftwareUpgrade")
)
var (
UBIPercentageSetEvent = mustGetEvent(ubiPoolABI, "UBIPercentageSet")
)
Functions ¶
func RegisterInterfaces ¶
func RegisterInterfaces(registry cdctypes.InterfaceRegistry)
func RegisterMsgServiceServer ¶
func RegisterMsgServiceServer(s grpc1.Server, srv MsgServiceServer)
Types ¶
type AccountKeeper ¶
type AccountKeeper interface {
GetModuleAddress(moduleName string) sdk.AccAddress
}
type DistrKeeper ¶ added in v0.12.0
type EVMEvent ¶
type EVMEvent struct { Address []byte `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` Topics [][]byte `protobuf:"bytes,2,rep,name=topics,proto3" json:"topics,omitempty"` Data []byte `protobuf:"bytes,3,opt,name=data,proto3" json:"data,omitempty"` }
EVMEvent represents a contract log event. Derived fields are not included in the protobuf.
func (*EVMEvent) Descriptor ¶
func (*EVMEvent) GetAddress ¶
func (*EVMEvent) MarshalToSizedBuffer ¶
func (*EVMEvent) ProtoMessage ¶
func (*EVMEvent) ProtoMessage()
func (*EVMEvent) ToEthLog ¶
ToEthLog converts an EVMEvent to an Ethereum Log. Note it assumes that Verify has been called before.
func (*EVMEvent) XXX_DiscardUnknown ¶
func (m *EVMEvent) XXX_DiscardUnknown()
func (*EVMEvent) XXX_Marshal ¶
func (*EVMEvent) XXX_Unmarshal ¶
type EvmEventProcessor ¶
type EvmEventProcessor interface { Name() string Prepare(ctx context.Context, blockHash common.Hash) ([]*EVMEvent, error) Addresses() []common.Address Deliver(ctx context.Context, blockHash common.Hash, log *EVMEvent) error }
EvmEventProcessor abstracts logic that processes EVM log events of the previous execution payload (current head) identified by the provided block hash.
EVMEngine calls this during PreparePayload to collect all EVM-log-events to include in the consensus block. It is also called during ProcessPayload to verify the proposed EVM events.
type EvmStakingKeeper ¶
type EvmStakingKeeper interface { ParseDepositLog(ethlog ethtypes.Log) (*bindings.IPTokenStakingDeposit, error) ParseWithdrawLog(ethlog ethtypes.Log) (*bindings.IPTokenStakingWithdraw, error) ProcessStakingEvents(ctx context.Context, height uint64, logs []*EVMEvent) error MaxWithdrawalPerBlock(ctx context.Context) (uint32, error) DequeueEligibleWithdrawals(ctx context.Context, maxDequeue uint32) (withdrawals ethtypes.Withdrawals, err error) PeekEligibleWithdrawals(ctx context.Context, maxPeek uint32) (withdrawals ethtypes.Withdrawals, err error) DequeueEligibleRewardWithdrawals(ctx context.Context, maxDequeue uint32) (withdrawals ethtypes.Withdrawals, err error) PeekEligibleRewardWithdrawals(ctx context.Context, maxPeek uint32) (withdrawals ethtypes.Withdrawals, err error) }
type ExecutionPayloadResponse ¶
type ExecutionPayloadResponse struct { }
func (*ExecutionPayloadResponse) Descriptor ¶
func (*ExecutionPayloadResponse) Descriptor() ([]byte, []int)
func (*ExecutionPayloadResponse) Marshal ¶
func (m *ExecutionPayloadResponse) Marshal() (dAtA []byte, err error)
func (*ExecutionPayloadResponse) MarshalTo ¶
func (m *ExecutionPayloadResponse) MarshalTo(dAtA []byte) (int, error)
func (*ExecutionPayloadResponse) MarshalToSizedBuffer ¶
func (m *ExecutionPayloadResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*ExecutionPayloadResponse) ProtoMessage ¶
func (*ExecutionPayloadResponse) ProtoMessage()
func (*ExecutionPayloadResponse) Reset ¶
func (m *ExecutionPayloadResponse) Reset()
func (*ExecutionPayloadResponse) Size ¶
func (m *ExecutionPayloadResponse) Size() (n int)
func (*ExecutionPayloadResponse) String ¶
func (m *ExecutionPayloadResponse) String() string
func (*ExecutionPayloadResponse) Unmarshal ¶
func (m *ExecutionPayloadResponse) Unmarshal(dAtA []byte) error
func (*ExecutionPayloadResponse) XXX_DiscardUnknown ¶
func (m *ExecutionPayloadResponse) XXX_DiscardUnknown()
func (*ExecutionPayloadResponse) XXX_Marshal ¶
func (m *ExecutionPayloadResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ExecutionPayloadResponse) XXX_Merge ¶
func (m *ExecutionPayloadResponse) XXX_Merge(src proto.Message)
func (*ExecutionPayloadResponse) XXX_Size ¶
func (m *ExecutionPayloadResponse) XXX_Size() int
func (*ExecutionPayloadResponse) XXX_Unmarshal ¶
func (m *ExecutionPayloadResponse) XXX_Unmarshal(b []byte) error
type GenesisState ¶
type GenesisState struct {
Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params"`
}
func DefaultGenesisState ¶
func DefaultGenesisState() *GenesisState
func NewGenesisState ¶
func NewGenesisState(params Params) *GenesisState
func (*GenesisState) Descriptor ¶
func (*GenesisState) Descriptor() ([]byte, []int)
func (*GenesisState) GetParams ¶
func (m *GenesisState) GetParams() Params
func (*GenesisState) Marshal ¶
func (m *GenesisState) Marshal() (dAtA []byte, err error)
func (*GenesisState) MarshalToSizedBuffer ¶
func (m *GenesisState) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*GenesisState) ProtoMessage ¶
func (*GenesisState) ProtoMessage()
func (*GenesisState) Reset ¶
func (m *GenesisState) Reset()
func (*GenesisState) Size ¶
func (m *GenesisState) Size() (n int)
func (*GenesisState) String ¶
func (m *GenesisState) String() string
func (*GenesisState) Unmarshal ¶
func (m *GenesisState) Unmarshal(dAtA []byte) error
func (*GenesisState) XXX_DiscardUnknown ¶
func (m *GenesisState) XXX_DiscardUnknown()
func (*GenesisState) XXX_Marshal ¶
func (m *GenesisState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*GenesisState) XXX_Merge ¶
func (m *GenesisState) XXX_Merge(src proto.Message)
func (*GenesisState) XXX_Size ¶
func (m *GenesisState) XXX_Size() int
func (*GenesisState) XXX_Unmarshal ¶
func (m *GenesisState) XXX_Unmarshal(b []byte) error
type MsgExecutionPayload ¶
type MsgExecutionPayload struct { Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` ExecutionPayload []byte `protobuf:"bytes,2,opt,name=execution_payload,json=executionPayload,proto3" json:"execution_payload,omitempty"` PrevPayloadEvents []*EVMEvent `protobuf:"bytes,3,rep,name=prev_payload_events,json=prevPayloadEvents,proto3" json:"prev_payload_events,omitempty"` }
MsgExecutionPayload defines the next EVM execution payload and the logs from previous execution payload.
func (*MsgExecutionPayload) Descriptor ¶
func (*MsgExecutionPayload) Descriptor() ([]byte, []int)
func (*MsgExecutionPayload) GetAuthority ¶
func (m *MsgExecutionPayload) GetAuthority() string
func (*MsgExecutionPayload) GetExecutionPayload ¶
func (m *MsgExecutionPayload) GetExecutionPayload() []byte
func (*MsgExecutionPayload) GetPrevPayloadEvents ¶
func (m *MsgExecutionPayload) GetPrevPayloadEvents() []*EVMEvent
func (*MsgExecutionPayload) Marshal ¶
func (m *MsgExecutionPayload) Marshal() (dAtA []byte, err error)
func (*MsgExecutionPayload) MarshalTo ¶
func (m *MsgExecutionPayload) MarshalTo(dAtA []byte) (int, error)
func (*MsgExecutionPayload) MarshalToSizedBuffer ¶
func (m *MsgExecutionPayload) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgExecutionPayload) ProtoMessage ¶
func (*MsgExecutionPayload) ProtoMessage()
func (*MsgExecutionPayload) Reset ¶
func (m *MsgExecutionPayload) Reset()
func (*MsgExecutionPayload) Size ¶
func (m *MsgExecutionPayload) Size() (n int)
func (*MsgExecutionPayload) String ¶
func (m *MsgExecutionPayload) String() string
func (*MsgExecutionPayload) Unmarshal ¶
func (m *MsgExecutionPayload) Unmarshal(dAtA []byte) error
func (*MsgExecutionPayload) XXX_DiscardUnknown ¶
func (m *MsgExecutionPayload) XXX_DiscardUnknown()
func (*MsgExecutionPayload) XXX_Marshal ¶
func (m *MsgExecutionPayload) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgExecutionPayload) XXX_Merge ¶
func (m *MsgExecutionPayload) XXX_Merge(src proto.Message)
func (*MsgExecutionPayload) XXX_Size ¶
func (m *MsgExecutionPayload) XXX_Size() int
func (*MsgExecutionPayload) XXX_Unmarshal ¶
func (m *MsgExecutionPayload) XXX_Unmarshal(b []byte) error
type MsgServiceClient ¶
type MsgServiceClient interface { // ExecutionPayload submits a new execution payload from consensus to the StoryEVM. ExecutionPayload(ctx context.Context, in *MsgExecutionPayload, opts ...grpc.CallOption) (*ExecutionPayloadResponse, error) }
MsgServiceClient is the client API for MsgService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewMsgServiceClient ¶
func NewMsgServiceClient(cc grpc1.ClientConn) MsgServiceClient
type MsgServiceServer ¶
type MsgServiceServer interface { // ExecutionPayload submits a new execution payload from consensus to the StoryEVM. ExecutionPayload(context.Context, *MsgExecutionPayload) (*ExecutionPayloadResponse, error) }
MsgServiceServer is the server API for MsgService service.
type Params ¶
type Params struct {
ExecutionBlockHash []byte `` /* 145-byte string literal not displayed */
}
Params defines the parameters for the module.
func (*Params) Descriptor ¶
func (*Params) GetExecutionBlockHash ¶
func (*Params) MarshalToSizedBuffer ¶
func (*Params) ProtoMessage ¶
func (*Params) ProtoMessage()
func (*Params) XXX_DiscardUnknown ¶
func (m *Params) XXX_DiscardUnknown()
func (*Params) XXX_Marshal ¶
func (*Params) XXX_Unmarshal ¶
type UnimplementedMsgServiceServer ¶
type UnimplementedMsgServiceServer struct { }
UnimplementedMsgServiceServer can be embedded to have forward compatible implementations.
func (*UnimplementedMsgServiceServer) ExecutionPayload ¶
func (*UnimplementedMsgServiceServer) ExecutionPayload(ctx context.Context, req *MsgExecutionPayload) (*ExecutionPayloadResponse, error)
type UpgradeKeeper ¶
type UpgradeKeeper interface {
ScheduleUpgrade(ctx context.Context, plan upgradetypes.Plan) error
}
type VoteExtensionProvider ¶
type VoteExtensionProvider interface {
PrepareVotes(ctx context.Context, commit abci.ExtendedCommitInfo) ([]sdk.Msg, error)
}
VoteExtensionProvider abstracts logic that provides consensus payload messages from the last commits vote extensions.
EVMEngine calls this during PreparePayload to collect all vote extensions msgs to include in the consensus block.