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 Etna P-chain metrics #3458

Draft
wants to merge 11 commits into
base: implement-acp-77-logging
Choose a base branch
from

Conversation

StephenButtolph
Copy link
Contributor

@StephenButtolph StephenButtolph commented Oct 10, 2024

Why this should be merged

Adds useful metrics:

# HELP avalanche_platformvm_gas_consumed Cumulative amount of gas consumed by transactions
# TYPE avalanche_platformvm_gas_consumed counter
avalanche_platformvm_gas_consumed{chain="P"} 482042
# HELP avalanche_platformvm_gas_capacity Minimum amount of gas that can be consumed in the next block
# TYPE avalanche_platformvm_gas_capacity gauge
avalanche_platformvm_gas_capacity{chain="P"} 999333
# HELP avalanche_platformvm_active_sovs Number of active Subnet only Validators
# TYPE avalanche_platformvm_active_sovs gauge
avalanche_platformvm_active_sovs{chain="P"} 9
# HELP avalanche_platformvm_excess Excess usage of a resource over the target usage
# TYPE avalanche_platformvm_excess gauge
avalanche_platformvm_excess{chain="P",resource="gas"} 667
avalanche_platformvm_excess{chain="P",resource="validators"} 0
# HELP avalanche_platformvm_price Price (in nAVAX) of a resource
# TYPE avalanche_platformvm_price gauge
avalanche_platformvm_price{chain="P",resource="gas"} 1
avalanche_platformvm_price{chain="P",resource="validators"} 1

How this works

Adds a metrics.Block that is passed into metrics.Metrics#MarkAccepted which includes useful information related to the Etna state.

How this was tested

  • Ran node on the devnet and metrics are exposed as expected.

@StephenButtolph StephenButtolph self-assigned this Oct 10, 2024
@StephenButtolph StephenButtolph marked this pull request as draft October 10, 2024 17:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant