Documentation ¶
Index ¶
- Constants
- func NewMsgServerImpl(keeper Keeper) types.MsgServer
- func NewRegistry() *registry
- type Keeper
- func (k Keeper) AddMessageEvidence(ctx sdk.Context, valAddr sdk.ValAddress, msg *types.MsgAddEvidence) error
- func (k Keeper) AddMessageSignature(ctx sdk.Context, valAddr sdk.ValAddress, ...) error
- func (k Keeper) CheckAndProcessAttestedMessages(ctx sdk.Context) error
- func (k Keeper) DeleteJob(ctx sdk.Context, queueTypeName string, id uint64) (err error)
- func (k Keeper) GetAllQueueNames(goCtx context.Context, req *types.QueryGetAllQueueNamesRequest) (*types.QueryGetAllQueueNamesResponse, error)
- func (k Keeper) GetMessagesForSigning(ctx sdk.Context, queueTypeName string, val sdk.ValAddress) (msgs []types.QueuedSignedMessageI, err error)
- func (k Keeper) GetMessagesFromQueue(ctx sdk.Context, queueTypeName string, n int) (msgs []types.QueuedSignedMessageI, err error)
- func (k Keeper) GetMessagesThatHaveReachedConsensus(ctx sdk.Context, queueTypeName string) ([]types.QueuedSignedMessageI, error)
- func (k Keeper) GetParams(ctx sdk.Context) types.Params
- func (k Keeper) Logger(ctx sdk.Context) log.Logger
- func (k Keeper) MessagesInQueue(goCtx context.Context, req *types.QueryMessagesInQueueRequest) (*types.QueryMessagesInQueueResponse, error)
- func (k Keeper) Params(c context.Context, req *types.QueryParamsRequest) (*types.QueryParamsResponse, error)
- func (k Keeper) PutMessageInQueue(ctx sdk.Context, queueTypeName string, msg consensus.ConsensusMsg, ...) error
- func (k Keeper) QueuedMessagesForSigning(goCtx context.Context, req *types.QueryQueuedMessagesForSigningRequest) (*types.QueryQueuedMessagesForSigningResponse, error)
- func (k Keeper) RemoveConsensusQueue(ctx sdk.Context, queueTypeName string) error
- func (k Keeper) SetMessagePublicAccessData(ctx sdk.Context, valAddr sdk.ValAddress, msg *types.MsgSetPublicAccessData) error
- func (k Keeper) SetParams(ctx sdk.Context, params types.Params)
- func (k Keeper) Store(ctx sdk.Context) sdk.KVStore
Constants ¶
View Source
const ( ErrConsensusQueueNotImplemented = whoops.Errorf("consensus queue not implemented for queueTypeName %s") ErrUnableToFindPubKeyForValidator = whoops.Errorf("unable to find public key for validator: %s") ErrSignatureVerificationFailed = whoops.Errorf("signature verification failed (msgId: %d, valAddr: %s, pubKey: %s)") ErrInvalidLimitValue = whoops.Errorf("invalid N value: %d") )
Variables ¶
This section is empty.
Functions ¶
func NewMsgServerImpl ¶
NewMsgServerImpl returns an implementation of the MsgServer interface for the provided Keeper.
func NewRegistry ¶
func NewRegistry() *registry
Types ¶
type Keeper ¶
type Keeper struct {
// contains filtered or unexported fields
}
func NewKeeper ¶
func NewKeeper( cdc codec.BinaryCodec, storeKey, memKey sdk.StoreKey, ps paramtypes.Subspace, valsetKeeper types.ValsetKeeper, reg *registry, ) *Keeper
func (Keeper) AddMessageEvidence ¶
func (k Keeper) AddMessageEvidence( ctx sdk.Context, valAddr sdk.ValAddress, msg *types.MsgAddEvidence, ) error
func (Keeper) AddMessageSignature ¶
func (k Keeper) AddMessageSignature( ctx sdk.Context, valAddr sdk.ValAddress, msgs []*types.ConsensusMessageSignature, ) error
AddMessageSignature adds signatures to the messages.
func (Keeper) CheckAndProcessAttestedMessages ¶
CheckAndProcessAttestedMessages is supposed to be used within the EndBlocker. It will get messages for the attestators that have reached a consensus and process them.
func (Keeper) GetAllQueueNames ¶
func (k Keeper) GetAllQueueNames(goCtx context.Context, req *types.QueryGetAllQueueNamesRequest) (*types.QueryGetAllQueueNamesResponse, error)
func (Keeper) GetMessagesForSigning ¶
func (k Keeper) GetMessagesForSigning(ctx sdk.Context, queueTypeName string, val sdk.ValAddress) (msgs []types.QueuedSignedMessageI, err error)
GetMessagesForSigning returns messages for a single validator that needs to be signed.
func (Keeper) GetMessagesFromQueue ¶
func (k Keeper) GetMessagesFromQueue(ctx sdk.Context, queueTypeName string, n int) (msgs []types.QueuedSignedMessageI, err error)
GetMessagesFromQueue gets N messages from the queue.
func (Keeper) GetMessagesThatHaveReachedConsensus ¶
func (k Keeper) GetMessagesThatHaveReachedConsensus(ctx sdk.Context, queueTypeName string) ([]types.QueuedSignedMessageI, error)
GetMessagesThatHaveReachedConsensus returns messages from a given queueTypeName that have reached consensus based on the latest snapshot available.
func (Keeper) MessagesInQueue ¶
func (k Keeper) MessagesInQueue(goCtx context.Context, req *types.QueryMessagesInQueueRequest) (*types.QueryMessagesInQueueResponse, error)
func (Keeper) Params ¶
func (k Keeper) Params(c context.Context, req *types.QueryParamsRequest) (*types.QueryParamsResponse, error)
func (Keeper) PutMessageInQueue ¶ added in v0.6.0
func (k Keeper) PutMessageInQueue(ctx sdk.Context, queueTypeName string, msg consensus.ConsensusMsg, opts *consensus.PutOptions) error
func (Keeper) QueuedMessagesForSigning ¶
func (k Keeper) QueuedMessagesForSigning(goCtx context.Context, req *types.QueryQueuedMessagesForSigningRequest) (*types.QueryQueuedMessagesForSigningResponse, error)
func (Keeper) RemoveConsensusQueue ¶
func (Keeper) SetMessagePublicAccessData ¶
func (k Keeper) SetMessagePublicAccessData( ctx sdk.Context, valAddr sdk.ValAddress, msg *types.MsgSetPublicAccessData, ) error
Source Files ¶
- attest.go
- concensus_keeper.go
- errors.go
- grpc_query.go
- grpc_query_get_all_queue_names.go
- grpc_query_messages_in_queue.go
- grpc_query_params.go
- keeper.go
- msg_server.go
- msg_server_add_evidence.go
- msg_server_delete_job.go
- msg_server_set_public_access_data.go
- params.go
- query_queued_messages_for_signing.go
- registry.go
Click to show internal directories.
Click to hide internal directories.