Struct ibc_telemetry::state::TelemetryState
source · pub struct TelemetryState { /* private fields */ }
Implementations§
source§impl TelemetryState
impl TelemetryState
pub fn new( tx_latency_submitted_range: Range<u64>, tx_latency_submitted_buckets: u64, tx_latency_confirmed_range: Range<u64>, tx_latency_confirmed_buckets: u64 ) -> Self
sourcepub fn gather(&self) -> Vec<MetricFamily>
pub fn gather(&self) -> Vec<MetricFamily>
Gather the metrics for export
pub fn init_worker_by_type(&self, worker_type: WorkerType)
pub fn init_per_chain(&self, chain_id: &ChainId)
pub fn init_per_channel( &self, src_chain: &ChainId, dst_chain: &ChainId, src_channel: &ChannelId, dst_channel: &ChannelId, src_port: &PortId, dst_port: &PortId )
pub fn init_per_path( &self, chain: &ChainId, counterparty: &ChainId, channel: &ChannelId, port: &PortId, clear_packets: bool )
pub fn init_per_client( &self, src_chain: &ChainId, dst_chain: &ChainId, client: &ClientId, misbehaviour: bool )
sourcepub fn worker(&self, worker_type: WorkerType, count: i64)
pub fn worker(&self, worker_type: WorkerType, count: i64)
Update the number of workers per object
sourcepub fn client_updates_submitted(
&self,
src_chain: &ChainId,
dst_chain: &ChainId,
client: &ClientId,
count: u64
)
pub fn client_updates_submitted( &self, src_chain: &ChainId, dst_chain: &ChainId, client: &ClientId, count: u64 )
Update the number of client updates per client
sourcepub fn client_updates_skipped(
&self,
src_chain: &ChainId,
dst_chain: &ChainId,
client: &ClientId,
count: u64
)
pub fn client_updates_skipped( &self, src_chain: &ChainId, dst_chain: &ChainId, client: &ClientId, count: u64 )
Update the number of client updates skipped per client
sourcepub fn client_misbehaviours_submitted(
&self,
src_chain: &ChainId,
dst_chain: &ChainId,
client: &ClientId,
count: u64
)
pub fn client_misbehaviours_submitted( &self, src_chain: &ChainId, dst_chain: &ChainId, client: &ClientId, count: u64 )
Number of client misbehaviours per client
sourcepub fn receive_packets_confirmed(
&self,
src_chain: &ChainId,
dst_chain: &ChainId,
src_channel: &ChannelId,
dst_channel: &ChannelId,
src_port: &PortId,
dst_port: &PortId,
count: u64
)
pub fn receive_packets_confirmed( &self, src_chain: &ChainId, dst_chain: &ChainId, src_channel: &ChannelId, dst_channel: &ChannelId, src_port: &PortId, dst_port: &PortId, count: u64 )
Number of receive packets relayed, per channel
sourcepub fn acknowledgment_packets_confirmed(
&self,
src_chain: &ChainId,
dst_chain: &ChainId,
src_channel: &ChannelId,
dst_channel: &ChannelId,
src_port: &PortId,
dst_port: &PortId,
count: u64
)
pub fn acknowledgment_packets_confirmed( &self, src_chain: &ChainId, dst_chain: &ChainId, src_channel: &ChannelId, dst_channel: &ChannelId, src_port: &PortId, dst_port: &PortId, count: u64 )
Number of acknowledgment packets relayed, per channel
sourcepub fn timeout_packets_confirmed(
&self,
src_chain: &ChainId,
dst_chain: &ChainId,
src_channel: &ChannelId,
dst_channel: &ChannelId,
src_port: &PortId,
dst_port: &PortId,
count: u64
)
pub fn timeout_packets_confirmed( &self, src_chain: &ChainId, dst_chain: &ChainId, src_channel: &ChannelId, dst_channel: &ChannelId, src_port: &PortId, dst_port: &PortId, count: u64 )
Number of timeout packets relayed, per channel
sourcepub fn query(&self, chain_id: &ChainId, query_type: &'static str)
pub fn query(&self, chain_id: &ChainId, query_type: &'static str)
Number of queries emitted by the relayer, per chain and query type
sourcepub fn queries_cache_hits(&self, chain_id: &ChainId, query_type: &'static str)
pub fn queries_cache_hits(&self, chain_id: &ChainId, query_type: &'static str)
Number of cache hits for queries emitted by the relayer, per chain and query type
sourcepub fn ws_reconnect(&self, chain_id: &ChainId)
pub fn ws_reconnect(&self, chain_id: &ChainId)
Number of time the relayer had to reconnect to the WebSocket endpoint, per chain
sourcepub fn ws_events(&self, chain_id: &ChainId, count: u64)
pub fn ws_events(&self, chain_id: &ChainId, count: u64)
How many IBC events did Hermes receive via the WebSocket subscription, per chain
sourcepub fn messages_submitted(&self, chain_id: &ChainId, count: u64)
pub fn messages_submitted(&self, chain_id: &ChainId, count: u64)
How many messages Hermes submitted to the chain
sourcepub fn wallet_balance(
&self,
chain_id: &ChainId,
account: &str,
amount: f64,
denom: &str
)
pub fn wallet_balance( &self, chain_id: &ChainId, account: &str, amount: f64, denom: &str )
The balance in each wallet that Hermes is using, per account, denom and chain.
The amount given is of unit: 10^6 * denom
pub fn received_event_batch(&self, tracking_id: impl ToString)
pub fn tx_submitted( &self, tx_count: usize, tracking_id: impl ToString, chain_id: &ChainId, channel_id: &ChannelId, port_id: &PortId, counterparty_chain_id: &ChainId )
pub fn tx_confirmed( &self, tx_count: usize, tracking_id: impl ToString, chain_id: &ChainId, channel_id: &ChannelId, port_id: &PortId, counterparty_chain_id: &ChainId )
pub fn send_packet_events( &self, _seq_nr: u64, _height: u64, chain_id: &ChainId, channel_id: &ChannelId, port_id: &PortId, counterparty_chain_id: &ChainId )
pub fn acknowledgement_events( &self, _seq_nr: u64, _height: u64, chain_id: &ChainId, channel_id: &ChannelId, port_id: &PortId, counterparty_chain_id: &ChainId )
pub fn timeout_events( &self, chain_id: &ChainId, channel_id: &ChannelId, port_id: &PortId, counterparty_chain_id: &ChainId )
pub fn cleared_send_packet_events( &self, _seq_nr: u64, _height: u64, chain_id: &ChainId, channel_id: &ChannelId, port_id: &PortId, counterparty_chain_id: &ChainId )
pub fn cleared_acknowledgment_events( &self, _seq_nr: u64, _height: u64, chain_id: &ChainId, channel_id: &ChannelId, port_id: &PortId, counterparty_chain_id: &ChainId )
sourcepub fn backlog_insert(
&self,
seq_nr: u64,
chain_id: &ChainId,
channel_id: &ChannelId,
port_id: &PortId,
counterparty_chain_id: &ChainId
)
pub fn backlog_insert( &self, seq_nr: u64, chain_id: &ChainId, channel_id: &ChannelId, port_id: &PortId, counterparty_chain_id: &ChainId )
Inserts in the backlog a new event for the given sequence number. This happens when the relayer observed a new SendPacket event.
sourcepub fn update_backlog(
&self,
sequences: Vec<u64>,
chain_id: &ChainId,
channel_id: &ChannelId,
port_id: &PortId,
counterparty_chain_id: &ChainId
)
pub fn update_backlog( &self, sequences: Vec<u64>, chain_id: &ChainId, channel_id: &ChannelId, port_id: &PortId, counterparty_chain_id: &ChainId )
Inserts in the backlog a new event for the given sequence number. This happens when the relayer observed a new SendPacket event.
sourcepub fn backlog_remove(
&self,
seq_nr: u64,
chain_id: &ChainId,
channel_id: &ChannelId,
port_id: &PortId,
counterparty_chain_id: &ChainId
)
pub fn backlog_remove( &self, seq_nr: u64, chain_id: &ChainId, channel_id: &ChannelId, port_id: &PortId, counterparty_chain_id: &ChainId )
Evicts from the backlog the event for the given sequence number. Removing events happens when the relayer observed either an acknowledgment or a timeout for a packet sequence number, which means that the corresponding packet was relayed.
sourcepub fn fees_amount(
&self,
chain_id: &ChainId,
receiver: &Signer,
fee_amounts: Coin<String>
)
pub fn fees_amount( &self, chain_id: &ChainId, receiver: &Signer, fee_amounts: Coin<String> )
Record the rewarded fee from ICS29 if the address is in the registered addresses list.
pub fn update_period_fees( &self, chain_id: &ChainId, receiver: &String, denom: &String )
pub fn add_visible_fee_address(&self, address: String)
sourcepub fn broadcast_errors(
&self,
address: &String,
error_code: u32,
error_description: &str
)
pub fn broadcast_errors( &self, address: &String, error_code: u32, error_description: &str )
Add an error and its description to the list of errors observed after broadcasting a Tx with a specific account.
sourcepub fn simulate_errors(
&self,
address: &String,
recoverable: bool,
error_description: String
)
pub fn simulate_errors( &self, address: &String, recoverable: bool, error_description: String )
Add an error and its description to the list of errors observed after simulating a Tx with a specific account.
pub fn dynamic_gas_queried_fees(&self, chain_id: &ChainId, amount: f64)
pub fn dynamic_gas_paid_fees(&self, chain_id: &ChainId, amount: f64)
pub fn dynamic_gas_queried_success_fees(&self, chain_id: &ChainId, amount: f64)
Auto Trait Implementations§
impl !Freeze for TelemetryState
impl !RefUnwindSafe for TelemetryState
impl Send for TelemetryState
impl Sync for TelemetryState
impl Unpin for TelemetryState
impl !UnwindSafe for TelemetryState
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
source§impl<T> FutureExt for T
impl<T> FutureExt for T
source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request