Documentation ¶
Index ¶
Constants ¶
View Source
const ( UP = 1 DOWN = 0 )
Variables ¶
This section is empty.
Functions ¶
func NewBridgeClient ¶
func NewClient ¶
func NewClient(cfg *config.ChainConfig) chain.IClient
NewClient initializes Client and returns the interface to chain.IClient
func NewEthClient ¶
func NewEthClient(rpcEndPoint string) ethClientI
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (*Client) FeedPacket ¶
FeedPacket spawsn few goroutines and starts to poll ethereum on regular interval. It uses filter logs method that specifically filters particular packet related logs. The range of block numbers to filter logs is set in defaultHeightDifferenceForFilterLogs. It parses the logs and if packet has destination chainID that this attestor supports then it will be send to the channel ch.
func (*Client) GetMissedPacket ¶
func (cl *Client) GetMissedPacket( ctx context.Context, missedPkt *chain.MissedPacket) ( *chain.Packet, error)
GetMissedPacket retrieves packet from source chain and returns it.
func (*Client) SetMetrics ¶
func (cl *Client) SetMetrics(metrics *metrics.PrometheusMetrics)
Click to show internal directories.
Click to hide internal directories.