Documentation ¶
Index ¶
- Constants
- Variables
- func Close() error
- func FlushSendQueue(chainId string, logger log.Logger, metrics prommetrics.Metrics) error
- func Run(cfg *config.Config, home string) error
- func RunGRPCQuery(ctx context.Context, client *lensclient.ChainClient, method string, ...) (abcitypes.ResponseQuery, metadata.MD, error)
- func Tx(client *lensclient.ChainClient, hash []byte) (tmtypes.TxProof, int64, error)
- type Clients
- type Query
- type TxResultMinimal
Constants ¶
const (
VERSION = "icq/v0.11.0"
)
Variables ¶
var ( MaxTxMsgs int WaitInterval = time.Second * 6 HistoricQueryInterval = time.Second * 15 TxMsgs = MaxTxMsgs LastReduced time.Time // Variables used for retries RtyAttNum = uint(5) RtyAtt = retry.Attempts(RtyAttNum) RtyDel = retry.Delay(time.Millisecond * 400) RtyErr = retry.LastErrorOnly(true) )
Functions ¶
func FlushSendQueue ¶
func RunGRPCQuery ¶
func RunGRPCQuery(ctx context.Context, client *lensclient.ChainClient, method string, reqBz []byte, md metadata.MD, metrics prommetrics.Metrics) (abcitypes.ResponseQuery, metadata.MD, error)
func Tx ¶
func Tx(client *lensclient.ChainClient, hash []byte) (tmtypes.TxProof, int64, error)
tm0.37 has a breaking change whereby tx events are no longer base64 encoded, so are represented as string and not bytes. As a result, we cannot use the RPCClient.Tx() method which attempts to unmarshal the Result, including the underlying Tx object. As such, we want to query the result directly, and unmarshal the json ourselves, to a representation of the result that conveniently does not contain the Tx object (that we don't use, because the TxProof already contains a byte representation of tx anyway!) Note: this function is compatible with 0.34 and 0.37 representations of transactions.
Types ¶
type Clients ¶
type Clients []*lensclient.ChainClient
func (Clients) GetForChainId ¶
func (clients Clients) GetForChainId(chainId string) *lensclient.ChainClient
type TxResultMinimal ¶
a minimised representation of the Tx emitted by a Tx query, only containing Height and Proof and thus compatbiel with tm0.34 and tm0.37.