Documentation
¶
Index ¶
- Constants
- func NewMsgServerImpl(keeper *Keeper) types.MsgServer
- func NewQueryServerImpl(k *Keeper) types.QueryServer
- type Keeper
- func (k Keeper) AddressCodec() address.Codec
- func (k Keeper) AuthenticateCapability(ctx sdk.Context, cap *capabilitytypes.Capability, name string) bool
- func (k Keeper) BindPort(ctx sdk.Context, portID string) error
- func (k Keeper) ChanCloseInit(ctx sdk.Context, portID, channelID string) error
- func (k Keeper) ClaimCapability(ctx sdk.Context, cap *capabilitytypes.Capability, name string) error
- func (k Keeper) GetAuthority() string
- func (k Keeper) GetPort(ctx sdk.Context) string
- func (k Keeper) InitializeConsumerClient(ctx sdk.Context) (string, error)
- func (k Keeper) Logger() log.Logger
- func (k Keeper) OnAcknowledgementMonitoringPacket(ctx sdk.Context, packet channeltypes.Packet, ...) error
- func (k Keeper) OnRecvMonitoringPacket(_ sdk.Context, _ channeltypes.Packet, _ networktypes.MonitoringPacket) (packetAck networktypes.MonitoringPacketAck, err error)
- func (k Keeper) OnTimeoutMonitoringPacket(_ sdk.Context, _ channeltypes.Packet, _ networktypes.MonitoringPacket) error
- func (k Keeper) RegisterConnectionChannelID(ctx sdk.Context, channelID string) error
- func (k Keeper) ReportBlockSignatures(ctx context.Context, lastCommit comet.CommitInfo, blockHeight int64) error
- func (k Keeper) ScopedKeeper() exported.ScopedKeeper
- func (k *Keeper) SetChannelKeeper(channelKeeper types.ChannelKeeper) error
- func (k *Keeper) SetClientKeeper(clientKeeper types.ClientKeeper) error
- func (k *Keeper) SetConnectionKeeper(connectionKeeper types.ConnectionKeeper) error
- func (k *Keeper) SetIBCKeeper(ibcKeeper *ibckeeper.Keeper) error
- func (k Keeper) SetPort(ctx sdk.Context, portID string)
- func (k *Keeper) SetPortKeeper(portKeeper types.PortKeeper) error
- func (k Keeper) ShouldBound(ctx sdk.Context, portID string) bool
- func (k Keeper) TransmitMonitoringPacket(ctx sdk.Context, packetData networktypes.MonitoringPacket, ...) (sequence uint64, err error)
- func (k Keeper) TransmitSignatures(ctx context.Context, blockHeight int64) (sequence uint64, err error)
- func (k Keeper) VerifyClientIDFromConnID(ctx sdk.Context, connID string) error
Constants ¶
const ( // MonitoringPacketTimeoutDelay is the delay before a monitoring packet is timed out // The timeout is set to one year // This is an arbitrarily chosen value that should never be reached in practice MonitoringPacketTimeoutDelay = time.Hour * 8760 )
Variables ¶
This section is empty.
Functions ¶
func NewMsgServerImpl ¶
NewMsgServerImpl returns an implementation of the MsgServer interface for the provided Keeper.
func NewQueryServerImpl ¶
func NewQueryServerImpl(k *Keeper) types.QueryServer
NewQueryServerImpl returns an implementation of the QueryServer interface for the provided Keeper.
Types ¶
type Keeper ¶
type Keeper struct {
Schema collections.Schema
Params collections.Item[types.Params]
MonitoringInfo collections.Item[types.MonitoringInfo]
ConnectionChannelID collections.Item[types.ConnectionChannelID]
ConsumerClientID collections.Item[types.ConsumerClientID]
// contains filtered or unexported fields
}
func NewKeeper ¶
func NewKeeper( cdc codec.BinaryCodec, addressCodec address.Codec, storeService store.KVStoreService, logger log.Logger, authority string, ibcKeeperFn func() *ibckeeper.Keeper, capabilityScopedFn func(string) capabilitykeeper.ScopedKeeper, stakingKeeper types.StakingKeeper, ) *Keeper
func (Keeper) AddressCodec ¶
AddressCodec returns the address codec.
func (Keeper) AuthenticateCapability ¶
func (k Keeper) AuthenticateCapability(ctx sdk.Context, cap *capabilitytypes.Capability, name string) bool
AuthenticateCapability wraps the scopedKeeper's AuthenticateCapability function
func (Keeper) BindPort ¶
BindPort defines a wrapper function for the port Keeper's function in order to expose it to module's InitGenesis function
func (Keeper) ChanCloseInit ¶
ChanCloseInit defines a wrapper function for the channel Keeper's function.
func (Keeper) ClaimCapability ¶
func (k Keeper) ClaimCapability(ctx sdk.Context, cap *capabilitytypes.Capability, name string) error
ClaimCapability allows the IBC app module to claim a capability that core IBC passes to it
func (Keeper) GetAuthority ¶
GetAuthority returns the module's authority.
func (Keeper) InitializeConsumerClient ¶
InitializeConsumerClient initializes the consumer IBC client and set it in the store
func (Keeper) OnAcknowledgementMonitoringPacket ¶
func (k Keeper) OnAcknowledgementMonitoringPacket( ctx sdk.Context, packet channeltypes.Packet, data networktypes.MonitoringPacket, ack channeltypes.Acknowledgement, ) error
OnAcknowledgementMonitoringPacket responds to the the success or failure of a packet acknowledgement written on the receiving chain.
func (Keeper) OnRecvMonitoringPacket ¶
func (k Keeper) OnRecvMonitoringPacket( _ sdk.Context, _ channeltypes.Packet, _ networktypes.MonitoringPacket, ) (packetAck networktypes.MonitoringPacketAck, err error)
OnRecvMonitoringPacket processes packet reception
func (Keeper) OnTimeoutMonitoringPacket ¶
func (k Keeper) OnTimeoutMonitoringPacket( _ sdk.Context, _ channeltypes.Packet, _ networktypes.MonitoringPacket, ) error
OnTimeoutMonitoringPacket responds to the case where a packet has not been transmitted because of a timeout
func (Keeper) RegisterConnectionChannelID ¶
RegisterConnectionChannelID registers the channel ID for the connection used with the consumer chain
func (Keeper) ReportBlockSignatures ¶
func (k Keeper) ReportBlockSignatures(ctx context.Context, lastCommit comet.CommitInfo, blockHeight int64) error
ReportBlockSignatures gets signatures from blocks and update monitoring info
func (Keeper) ScopedKeeper ¶
func (k Keeper) ScopedKeeper() exported.ScopedKeeper
ScopedKeeper returns the ScopedKeeper
func (*Keeper) SetChannelKeeper ¶
func (k *Keeper) SetChannelKeeper(channelKeeper types.ChannelKeeper) error
SetChannelKeeper sets IBC channel keeper
func (*Keeper) SetClientKeeper ¶
func (k *Keeper) SetClientKeeper(clientKeeper types.ClientKeeper) error
SetClientKeeper sets IBC client keeper
func (*Keeper) SetConnectionKeeper ¶
func (k *Keeper) SetConnectionKeeper(connectionKeeper types.ConnectionKeeper) error
SetConnectionKeeper sets IBC connection keeper
func (*Keeper) SetIBCKeeper ¶
SetIBCKeeper sets the IBC Keeper
func (*Keeper) SetPortKeeper ¶
func (k *Keeper) SetPortKeeper(portKeeper types.PortKeeper) error
SetPortKeeper sets IBC port keeper
func (Keeper) ShouldBound ¶
ShouldBound checks if the IBC app module can be bound to the desired port
func (Keeper) TransmitMonitoringPacket ¶
func (k Keeper) TransmitMonitoringPacket( ctx sdk.Context, packetData networktypes.MonitoringPacket, sourcePort, sourceChannel string, timeoutHeight clienttypes.Height, timeoutTimestamp uint64, ) (sequence uint64, err error)
TransmitMonitoringPacket transmits the packet over IBC with the specified source port and source channel
func (Keeper) TransmitSignatures ¶
func (k Keeper) TransmitSignatures(ctx context.Context, blockHeight int64) (sequence uint64, err error)
TransmitSignatures transmits over IBC the signatures to consumer if height is reached and signatures are not yet transmitted
func (Keeper) VerifyClientIDFromConnID ¶
VerifyClientIDFromConnID verifies if the client ID associated with the provided connection ID is the consumer client ID and if no connection is yet established with the consumer chain this operation should be performed at OnChanOpenTry handshake phase