-
Notifications
You must be signed in to change notification settings - Fork 88
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(sequencer-relayer): add metrics for recording Celestia fees (#1742
) ## Summary This adds three new gauges to the relayer metrics to record the Celestia fees incurred in the latest submission: total fees, cost per uncompressed byte and cost per compressed byte. ## Background The new metrics could provide useful information. ## Changes - Added three new metrics. - Provided `IntoF64` for `u64` (for one of the new metrics) and for `u128` (for a recently-added bridge-withdrawer metric) - Added warnings to `IntoF64` impls which have the potential for precision loss ## Testing Tests for metrics are generally still pending. Checked the new metrics were being populated in a relayer on a local testnet. Example output: ``` # HELP astria_sequencer_relayer_celestia_fees_total_utia The total Celestia fees in utia for the latest successful submission # TYPE astria_sequencer_relayer_celestia_fees_total_utia gauge astria_sequencer_relayer_celestia_fees_total_utia{service="astria-sequencer-relayer"} 186 # HELP astria_sequencer_relayer_celestia_fees_utia_per_uncompressed_blob_byte The Celestia fees in utia per uncompressed blob byte for the latest successful submission # TYPE astria_sequencer_relayer_celestia_fees_utia_per_uncompressed_blob_byte gauge astria_sequencer_relayer_celestia_fees_utia_per_uncompressed_blob_byte{service="astria-sequencer-relayer"} 0.07080319756376094 # HELP astria_sequencer_relayer_celestia_fees_utia_per_compressed_blob_byte The Celestia fees in utia per compressed blob byte for the latest successful submission # TYPE astria_sequencer_relayer_celestia_fees_utia_per_compressed_blob_byte gauge astria_sequencer_relayer_celestia_fees_utia_per_compressed_blob_byte{service="astria-sequencer-relayer"} 0.12836438923395446 ``` ## Metrics New metrics: - `astria_sequencer_relayer_celestia_fees_total_utia` - `astria_sequencer_relayer_celestia_fees_utia_per_uncompressed_blob_byte` - `astria_sequencer_relayer_celestia_fees_utia_per_compressed_blob_byte` ## Related Issues Closes #1734.
- Loading branch information
Showing
6 changed files
with
172 additions
and
58 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.