Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add missing prometheus metrics #219

Merged
merged 2 commits into from
Oct 8, 2024
Merged

Add missing prometheus metrics #219

merged 2 commits into from
Oct 8, 2024

Conversation

thaarok
Copy link
Collaborator

@thaarok thaarok commented Oct 4, 2024

Fixes #218.
Add following prometheus metrics, used in Norma testing:

  • chain_execution_nonresetting - because original chain_execution metrics is being reset regularly in the new ethereum, I am adding the original non-resetted metrics as a new metric.
  • chain_info metrics added in the new ethereum made working by setting the chain_id into it
# TYPE chain_info gauge
chain_info {chain_id="4003"} 1

# TYPE chain_execution_count counter - is being reset to zero regularly with the new ethereum
chain_execution_count 1

# TYPE chain_execution summary - is being reset to zero regularly with the new ethereum
chain_execution {quantile="0.5"} 151768
chain_execution {quantile="0.75"} 151768
chain_execution {quantile="0.95"} 151768
chain_execution {quantile="0.99"} 151768
chain_execution {quantile="0.999"} 151768
chain_execution {quantile="0.9999"} 151768

# TYPE chain_execution_nonresetting_count counter - replacement of old chain_execution_count
chain_execution_nonresetting_count 9

# TYPE chain_execution_nonresetting summary - replacement of old chain_execution
chain_execution_nonresetting {quantile="0.5"} 138109
chain_execution_nonresetting {quantile="0.75"} 800485
chain_execution_nonresetting {quantile="0.95"} 2.499486e+06
chain_execution_nonresetting {quantile="0.99"} 2.499486e+06
chain_execution_nonresetting {quantile="0.999"} 2.499486e+06
chain_execution_nonresetting {quantile="0.9999"} 2.499486e+06

@rpl-ffl
Copy link
Collaborator

rpl-ffl commented Oct 7, 2024

Thank you for the quick fix.

  1. These changes help to fix Norma issue:

    • chain_execution -> chain_execution_nonreseting
    • chain_execution_count -> chain_execution_nonreseting_count
  2. The change chain_info {} 1 -> chain_info {chain_id="4003"} 1 does not help to fix the Norma issue. Norma rigidly tries to parse the second element as so:

    quantileReg = regexp.MustCompile(`.*{quantile=".*"}`)
    

    For now we're circumventing this issue by ignoring any value with the name chain_info.

@thaarok thaarok merged commit 2d21d0b into develop Oct 8, 2024
1 check passed
@thaarok thaarok deleted the jk/prometheus-readd branch October 8, 2024 08:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants