Documentation
¶
Index ¶
- Constants
- Variables
- type AppModule
- func (a AppModule) ExtendVote(ctx sdk.Context, vote *abci.RequestExtendVote) (*abci.ResponseExtendVote, error)
- func (a AppModule) GetSidecarAddress(ctx sdk.Context) string
- func (a AppModule) PreBlocker(ctx sdk.Context, req *abci.RequestFinalizeBlock, i int) error
- func (a AppModule) PrepareProposal(ctx sdk.Context, proposal *abci.RequestPrepareProposal, bytes []byte) (*abci.ResponsePrepareProposal, error)
- func (a AppModule) ProcessProposal(ctx sdk.Context, req *abci.RequestProcessProposal, i int) (*abci.ResponseProcessProposal, error)
- func (a AppModule) VerifyVote(ctx sdk.Context, req *abci.RequestVerifyVoteExtension) (*abci.ResponseVerifyVoteExtension, error)
- type AppModuleBasic
- func (AppModuleBasic) IsAppModule()
- func (AppModuleBasic) IsOnePerModuleType()
- func (a AppModuleBasic) Name() string
- func (a AppModuleBasic) RegisterGRPCGatewayRoutes(context client.Context, mux *runtime.ServeMux)
- func (a AppModuleBasic) RegisterInterfaces(registry types.InterfaceRegistry)
- func (a AppModuleBasic) RegisterLegacyAminoCodec(amino *codec.LegacyAmino)
- type ClientUpdate
- func (*ClientUpdate) Descriptor() ([]byte, []int)
- func (m *ClientUpdate) GetAttestationClaim() lightclient.AttestationClaim
- func (m *ClientUpdate) GetClientToUpdate() string
- func (m *ClientUpdate) Marshal() (dAtA []byte, err error)
- func (m *ClientUpdate) MarshalTo(dAtA []byte) (int, error)
- func (m *ClientUpdate) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*ClientUpdate) ProtoMessage()
- func (m *ClientUpdate) Reset()
- func (m *ClientUpdate) Size() (n int)
- func (m *ClientUpdate) String() string
- func (m *ClientUpdate) Unmarshal(dAtA []byte) error
- func (m *ClientUpdate) XXX_DiscardUnknown()
- func (m *ClientUpdate) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ClientUpdate) XXX_Merge(src proto.Message)
- func (m *ClientUpdate) XXX_Size() int
- func (m *ClientUpdate) XXX_Unmarshal(b []byte) error
- type ClientUpdates
- func (*ClientUpdates) Descriptor() ([]byte, []int)
- func (m *ClientUpdates) GetClientUpdates() []ClientUpdate
- func (m *ClientUpdates) Marshal() (dAtA []byte, err error)
- func (m *ClientUpdates) MarshalTo(dAtA []byte) (int, error)
- func (m *ClientUpdates) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*ClientUpdates) ProtoMessage()
- func (m *ClientUpdates) Reset()
- func (m *ClientUpdates) Size() (n int)
- func (m *ClientUpdates) String() string
- func (m *ClientUpdates) Unmarshal(dAtA []byte) error
- func (m *ClientUpdates) XXX_DiscardUnknown()
- func (m *ClientUpdates) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ClientUpdates) XXX_Merge(src proto.Message)
- func (m *ClientUpdates) XXX_Size() int
- func (m *ClientUpdates) XXX_Unmarshal(b []byte) error
- type SidecarConfig
- type VoteExtension
- func (*VoteExtension) Descriptor() ([]byte, []int)
- func (m *VoteExtension) GetAttestations() []types.Attestation
- func (m *VoteExtension) Marshal() (dAtA []byte, err error)
- func (m *VoteExtension) MarshalTo(dAtA []byte) (int, error)
- func (m *VoteExtension) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*VoteExtension) ProtoMessage()
- func (m *VoteExtension) Reset()
- func (m *VoteExtension) Size() (n int)
- func (m *VoteExtension) String() string
- func (m *VoteExtension) Unmarshal(dAtA []byte) error
- func (m *VoteExtension) XXX_DiscardUnknown()
- func (m *VoteExtension) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *VoteExtension) XXX_Merge(src proto.Message)
- func (m *VoteExtension) XXX_Size() int
- func (m *VoteExtension) XXX_Unmarshal(b []byte) error
Constants ¶
const ( SidecarAddressEnv = "ATTESTATION_SIDECAR_ADDRESS" SidecarConfigPathEnv = "ATTESTATION_SIDECAR_CONFIG_PATH" )
const ModuleName = "attestationvoteextension"
Variables ¶
Functions ¶
This section is empty.
Types ¶
type AppModule ¶
type AppModule struct {
AppModuleBasic
// contains filtered or unexported fields
}
AppModule is the application module for the attestation vote extension module
func NewAppModule ¶
func NewAppModule(trustedUpdateClientFunc lightclient.TrustedClientUpdateFunc, cdc codec.Codec) AppModule
NewAppModule creates a new attestation vote extension AppModule
func (AppModule) ExtendVote ¶
func (a AppModule) ExtendVote(ctx sdk.Context, vote *abci.RequestExtendVote) (*abci.ResponseExtendVote, error)
ExtendVote asks sidecar for attestations and return vote extension
func (AppModule) PreBlocker ¶
TODO: Document Contract: We do not need to check if vote extensions are enabled as that is dealt with by the top level handler
func (AppModule) PrepareProposal ¶
func (a AppModule) PrepareProposal(ctx sdk.Context, proposal *abci.RequestPrepareProposal, bytes []byte) (*abci.ResponsePrepareProposal, error)
TODO: Document Contract: We do not need to check if vote extensions are enabled as that is dealt with by the top level handler
func (AppModule) ProcessProposal ¶
func (a AppModule) ProcessProposal(ctx sdk.Context, req *abci.RequestProcessProposal, i int) (*abci.ResponseProcessProposal, error)
TODO: Document Contract: We do not need to check if vote extensions are enabled as that is dealt with by the top level handler
func (AppModule) VerifyVote ¶
func (a AppModule) VerifyVote(ctx sdk.Context, req *abci.RequestVerifyVoteExtension) (*abci.ResponseVerifyVoteExtension, error)
TODO: Document
type AppModuleBasic ¶
type AppModuleBasic struct{}
func (AppModuleBasic) IsAppModule ¶
func (AppModuleBasic) IsAppModule()
IsAppModule implements the appmodule.AppModule interface.
func (AppModuleBasic) IsOnePerModuleType ¶
func (AppModuleBasic) IsOnePerModuleType()
IsOnePerModuleType implements the depinject.OnePerModuleType interface.
func (AppModuleBasic) Name ¶
func (a AppModuleBasic) Name() string
func (AppModuleBasic) RegisterGRPCGatewayRoutes ¶
func (a AppModuleBasic) RegisterGRPCGatewayRoutes(context client.Context, mux *runtime.ServeMux)
RegisterGRPCGatewayRoutes performs a no-op.
func (AppModuleBasic) RegisterInterfaces ¶
func (a AppModuleBasic) RegisterInterfaces(registry types.InterfaceRegistry)
RegisterInterfaces registers module concrete types into protobuf Any.
func (AppModuleBasic) RegisterLegacyAminoCodec ¶
func (a AppModuleBasic) RegisterLegacyAminoCodec(amino *codec.LegacyAmino)
RegisterLegacyAminoCodec performs a no-op. The attestation vote extension does not support amino.
type ClientUpdate ¶
type ClientUpdate struct {
ClientToUpdate string `protobuf:"bytes,1,opt,name=client_to_update,json=clientToUpdate,proto3" json:"client_to_update,omitempty"`
AttestationClaim lightclient.AttestationClaim `protobuf:"bytes,2,opt,name=attestation_claim,json=attestationClaim,proto3" json:"attestation_claim"`
}
func (*ClientUpdate) Descriptor ¶
func (*ClientUpdate) Descriptor() ([]byte, []int)
func (*ClientUpdate) GetAttestationClaim ¶
func (m *ClientUpdate) GetAttestationClaim() lightclient.AttestationClaim
func (*ClientUpdate) GetClientToUpdate ¶
func (m *ClientUpdate) GetClientToUpdate() string
func (*ClientUpdate) Marshal ¶
func (m *ClientUpdate) Marshal() (dAtA []byte, err error)
func (*ClientUpdate) MarshalToSizedBuffer ¶
func (m *ClientUpdate) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*ClientUpdate) ProtoMessage ¶
func (*ClientUpdate) ProtoMessage()
func (*ClientUpdate) Reset ¶
func (m *ClientUpdate) Reset()
func (*ClientUpdate) Size ¶
func (m *ClientUpdate) Size() (n int)
func (*ClientUpdate) String ¶
func (m *ClientUpdate) String() string
func (*ClientUpdate) Unmarshal ¶
func (m *ClientUpdate) Unmarshal(dAtA []byte) error
func (*ClientUpdate) XXX_DiscardUnknown ¶
func (m *ClientUpdate) XXX_DiscardUnknown()
func (*ClientUpdate) XXX_Marshal ¶
func (m *ClientUpdate) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ClientUpdate) XXX_Merge ¶
func (m *ClientUpdate) XXX_Merge(src proto.Message)
func (*ClientUpdate) XXX_Size ¶
func (m *ClientUpdate) XXX_Size() int
func (*ClientUpdate) XXX_Unmarshal ¶
func (m *ClientUpdate) XXX_Unmarshal(b []byte) error
type ClientUpdates ¶
type ClientUpdates struct {
ClientUpdates []ClientUpdate `protobuf:"bytes,1,rep,name=client_updates,json=clientUpdates,proto3" json:"client_updates"`
}
func (*ClientUpdates) Descriptor ¶
func (*ClientUpdates) Descriptor() ([]byte, []int)
func (*ClientUpdates) GetClientUpdates ¶
func (m *ClientUpdates) GetClientUpdates() []ClientUpdate
func (*ClientUpdates) Marshal ¶
func (m *ClientUpdates) Marshal() (dAtA []byte, err error)
func (*ClientUpdates) MarshalToSizedBuffer ¶
func (m *ClientUpdates) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*ClientUpdates) ProtoMessage ¶
func (*ClientUpdates) ProtoMessage()
func (*ClientUpdates) Reset ¶
func (m *ClientUpdates) Reset()
func (*ClientUpdates) Size ¶
func (m *ClientUpdates) Size() (n int)
func (*ClientUpdates) String ¶
func (m *ClientUpdates) String() string
func (*ClientUpdates) Unmarshal ¶
func (m *ClientUpdates) Unmarshal(dAtA []byte) error
func (*ClientUpdates) XXX_DiscardUnknown ¶
func (m *ClientUpdates) XXX_DiscardUnknown()
func (*ClientUpdates) XXX_Marshal ¶
func (m *ClientUpdates) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ClientUpdates) XXX_Merge ¶
func (m *ClientUpdates) XXX_Merge(src proto.Message)
func (*ClientUpdates) XXX_Size ¶
func (m *ClientUpdates) XXX_Size() int
func (*ClientUpdates) XXX_Unmarshal ¶
func (m *ClientUpdates) XXX_Unmarshal(b []byte) error
type SidecarConfig ¶
type SidecarConfig struct {
SidecarAddress string `json:"sidecar_address"`
}
type VoteExtension ¶
type VoteExtension struct {
// one attestation for every chain configured in the sidecar
Attestations []types.Attestation `protobuf:"bytes,1,rep,name=attestations,proto3" json:"attestations"`
}
func (*VoteExtension) Descriptor ¶
func (*VoteExtension) Descriptor() ([]byte, []int)
func (*VoteExtension) GetAttestations ¶
func (m *VoteExtension) GetAttestations() []types.Attestation
func (*VoteExtension) Marshal ¶
func (m *VoteExtension) Marshal() (dAtA []byte, err error)
func (*VoteExtension) MarshalToSizedBuffer ¶
func (m *VoteExtension) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*VoteExtension) ProtoMessage ¶
func (*VoteExtension) ProtoMessage()
func (*VoteExtension) Reset ¶
func (m *VoteExtension) Reset()
func (*VoteExtension) Size ¶
func (m *VoteExtension) Size() (n int)
func (*VoteExtension) String ¶
func (m *VoteExtension) String() string
func (*VoteExtension) Unmarshal ¶
func (m *VoteExtension) Unmarshal(dAtA []byte) error
func (*VoteExtension) XXX_DiscardUnknown ¶
func (m *VoteExtension) XXX_DiscardUnknown()
func (*VoteExtension) XXX_Marshal ¶
func (m *VoteExtension) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*VoteExtension) XXX_Merge ¶
func (m *VoteExtension) XXX_Merge(src proto.Message)
func (*VoteExtension) XXX_Size ¶
func (m *VoteExtension) XXX_Size() int
func (*VoteExtension) XXX_Unmarshal ¶
func (m *VoteExtension) XXX_Unmarshal(b []byte) error