Skip to content

Add configurable namespace to telemetry#4381

Merged
ljoss17 merged 3 commits intomasterfrom
luca_joss/add-hermes-namespace-to-metrics
Jun 25, 2025
Merged

Add configurable namespace to telemetry#4381
ljoss17 merged 3 commits intomasterfrom
luca_joss/add-hermes-namespace-to-metrics

Conversation

@ljoss17
Copy link
Contributor

@ljoss17 ljoss17 commented Jun 24, 2025

Closes: #4380

Description

This PR adds a new optional configuration, prefix for the telemetry.
When this is set to something other than an empty string this will make all the metrics prefixed with the configured value.

E.g prefix = "hermes":

hermes_acknowledgement_events_total{chain="ibc-0",channel="channel-0",counterparty="ibc-1",port="transfer",otel_scope_name="hermes"} 3
hermes_send_packet_events_total{chain="ibc-0",channel="channel-0",counterparty="ibc-1",port="transfer",otel_scope_name="hermes"} 3

E.g prefix = "" or prefix not set:

acknowledgement_events_total{chain="ibc-0",channel="channel-0",counterparty="ibc-1",port="transfer",otel_scope_name="hermes"} 3
send_packet_events_total{chain="ibc-0",channel="channel-0",counterparty="ibc-1",port="transfer",otel_scope_name="hermes"} 3

PR author checklist:

  • Added changelog entry, using unclog.
  • Added tests: integration (for Hermes) or unit/mock tests (for modules).
  • Linked to GitHub issue.
  • Updated code comments and documentation (e.g., docs/).
  • Tagged one reviewer who will be the one responsible for shepherding this PR.

Reviewer checklist:

  • Reviewed Files changed in the GitHub PR explorer.
  • Manually tested (in case integration/unit/mock tests are absent).

@ljoss17 ljoss17 requested a review from romac June 24, 2025 12:38
@ljoss17 ljoss17 added I: telemetry Internal: related to Telemetry & metrics I: configuration Internal: related to Hermes configuration labels Jun 24, 2025
Copy link
Contributor

@adizere adizere left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

an operator should ideally test this

@ljoss17 ljoss17 added this pull request to the merge queue Jun 25, 2025
Merged via the queue into master with commit 9a742bc Jun 25, 2025
52 of 53 checks passed
@ljoss17 ljoss17 deleted the luca_joss/add-hermes-namespace-to-metrics branch June 25, 2025 06:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

I: configuration Internal: related to Hermes configuration I: telemetry Internal: related to Telemetry & metrics

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add Prometheus metric namespace

2 participants