Documentation ¶
Index ¶
- Variables
- type Chain
- type ChainRuntime
- type Chains
- type Relayer
- func (r *Relayer) CheckFinality(ctx context.Context)
- func (r *Relayer) ClearMessages(ctx context.Context, msgs []*types.MessageKey, srcChain *ChainRuntime) error
- func (r *Relayer) FindChainRuntime(nId string) (*ChainRuntime, error)
- func (r *Relayer) GetAllChainsRuntime() []*ChainRuntime
- func (r *Relayer) GetBlockStore() *store.BlockStore
- func (r *Relayer) GetMessageStore() *store.MessageStore
- func (r *Relayer) HandleMessageFailed(routeMessage *types.RouteMessage, dst, src *ChainRuntime, txHash string, ...)
- func (r *Relayer) PruneDB() error
- func (r *Relayer) RouteMessage(ctx context.Context, m *types.RouteMessage, dst, src *ChainRuntime)
- func (r *Relayer) SaveBlockHeight(ctx context.Context, chainRuntime *ChainRuntime, height uint64) error
- func (r *Relayer) SaveChainsBlockHeight(ctx context.Context)
- func (r *Relayer) Start(ctx context.Context, flushInterval time.Duration, fresh bool) (chan error, error)
- func (r *Relayer) StartBlockProcessors(ctx context.Context, errorChan chan error)
- func (r *Relayer) StartChainListeners(ctx context.Context, errCh chan error)
- func (r *Relayer) StartFinalityProcessor(ctx context.Context)
- func (r *Relayer) StartRouter(ctx context.Context, flushInterval time.Duration)
Constants ¶
This section is empty.
Variables ¶
Functions ¶
This section is empty.
Types ¶
type Chain ¶
type Chain struct { ChainProvider provider.ChainProvider // contains filtered or unexported fields }
type ChainRuntime ¶
type ChainRuntime struct { Provider provider.ChainProvider LastBlockHeight uint64 LastSavedHeight uint64 MessageCache *types.MessageCache // contains filtered or unexported fields }
func NewChainRuntime ¶
func NewChainRuntime(log *zap.Logger, chain *Chain) (*ChainRuntime, error)
type Chains ¶
Chains is a collection of Chain (mapped by chain_name)
type Relayer ¶
type Relayer struct {
// contains filtered or unexported fields
}
func NewRelayer ¶
func (*Relayer) CheckFinality ¶
func (*Relayer) ClearMessages ¶
func (r *Relayer) ClearMessages(ctx context.Context, msgs []*types.MessageKey, srcChain *ChainRuntime) error
func (*Relayer) FindChainRuntime ¶
func (r *Relayer) FindChainRuntime(nId string) (*ChainRuntime, error)
func (*Relayer) GetAllChainsRuntime ¶
func (r *Relayer) GetAllChainsRuntime() []*ChainRuntime
func (*Relayer) GetBlockStore ¶
func (r *Relayer) GetBlockStore() *store.BlockStore
GetBlockStore returns the block store
func (*Relayer) GetMessageStore ¶
func (r *Relayer) GetMessageStore() *store.MessageStore
GetBlockStore returns the block store
func (*Relayer) HandleMessageFailed ¶
func (r *Relayer) HandleMessageFailed(routeMessage *types.RouteMessage, dst, src *ChainRuntime, txHash string, err error)
func (*Relayer) RouteMessage ¶
func (r *Relayer) RouteMessage(ctx context.Context, m *types.RouteMessage, dst, src *ChainRuntime)
func (*Relayer) SaveBlockHeight ¶
func (*Relayer) SaveChainsBlockHeight ¶ added in v1.2.0
SaveBlockHeight for all chains
func (*Relayer) Start ¶
func (r *Relayer) Start(ctx context.Context, flushInterval time.Duration, fresh bool) (chan error, error)
main start loop
func (*Relayer) StartBlockProcessors ¶
func (*Relayer) StartChainListeners ¶
func (*Relayer) StartFinalityProcessor ¶
Click to show internal directories.
Click to hide internal directories.