Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Histogram support in runtime metrics #6935

Merged
merged 21 commits into from
Mar 28, 2023
Merged

Conversation

tdimitrov
Copy link
Contributor

Add support for histograms to the runtime metrics. Additionally add polkadot_parachain_verify_dispute_signature histogram which tracks the time needed from the runtime to verify a single validator signature of a dispute statement.

Add support for histograms to the runtime metrics. Additionally add
`polkadot_parachain_verify_dispute_signature` histogram which tracks the
time needed from the runtime to verify a single validator signature of a
dispute statement.
@tdimitrov tdimitrov added A0-please_review Pull request needs code review. B0-silent Changes should not be mentioned in any release notes C1-low PR touches the given topic and has a low impact on builders. T4-parachains_engineering This PR/Issue is related to Parachains performance, stability, maintenance. labels Mar 21, 2023
@tdimitrov tdimitrov requested a review from sandreim March 21, 2023 20:45
@@ -176,4 +188,14 @@ pub mod metric_definitions {
description: "Counts the number of bitfields signature checked in `enter_inner`.",
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This metric doesn't work (before and after my changes) for some reason - it's not reported at all by prometheus. I'll investigate further.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I've created a follow up issue for this: https://github.com/paritytech/polkadot/issues/6943

@tdimitrov tdimitrov added the D3-trivial 🧸 PR contains trivial changes in a runtime directory that do not require an audit. label Mar 21, 2023
runtime/metrics/Cargo.toml Outdated Show resolved Hide resolved
@tdimitrov
Copy link
Contributor Author

Result on Versi:

image

@@ -20,30 +20,33 @@
//! tracing support. This requires that the custom profiler (`TraceHandler`) to be
//! registered in substrate via a `logger_hook()`. Events emitted from runtime are
//! then captured/processed by the `TraceHandler` implementation.
//!
//! Don't add logs in this file because it gets executed before the logger is
Copy link
Contributor

Choose a reason for hiding this comment

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

👍

node/metrics/src/runtime/mod.rs Show resolved Hide resolved
runtime/parachains/src/disputes.rs Outdated Show resolved Hide resolved
primitives/src/v4/metrics.rs Outdated Show resolved Hide resolved
@eskimor
Copy link
Member

eskimor commented Mar 28, 2023

Do you have a link to that Versi histogram - I would love to have a closer look.

@tdimitrov
Copy link
Contributor Author

Yes @eskimor: https://grafana.parity-mgmt.parity.io/d/rrbzx79nz/disputes?orgId=1&var-data_source=thanos&var-chain=versi_v1_10&from=1679574006458&to=1679587000062

Ignore the Inf values at the beginning of the period - there was a bug in the calculation and the buckets weren't set properly.

@tdimitrov
Copy link
Contributor Author

bot merge

@paritytech-processbot paritytech-processbot bot merged commit cf83a14 into master Mar 28, 2023
@paritytech-processbot paritytech-processbot bot deleted the tsv-runtime-metrics branch March 28, 2023 13:37
ordian added a commit that referenced this pull request Mar 29, 2023
* master:
  Companion: wasm-builder support stable Rust (#6967)
  Fix feature (#6966)
  configuration: backport async backing parameters from the feature branch (#6961)
  Histogram support in runtime metrics (#6935)
  Bump openssl from 0.10.38 to 0.10.48 (#6955)
  Proxy for Nomination Pools (#6846)
  Nomination Pools migration v5: RewardPool fix (#6957)
  bump timestamp script to v0.2 (#6954)
  Subsystem channel tweaks (#6905)
  Companion for #13683 (#6944)
  inherent disputes: remove per block initializer and disputes timeout event (#6937)
ordian added a commit that referenced this pull request Mar 29, 2023
…slashing-client

* ao-past-session-slashing-runtime:
  Companion: wasm-builder support stable Rust (#6967)
  Fix feature (#6966)
  configuration: backport async backing parameters from the feature branch (#6961)
  Histogram support in runtime metrics (#6935)
  Bump openssl from 0.10.38 to 0.10.48 (#6955)
  Proxy for Nomination Pools (#6846)
  Nomination Pools migration v5: RewardPool fix (#6957)
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A0-please_review Pull request needs code review. B0-silent Changes should not be mentioned in any release notes C1-low PR touches the given topic and has a low impact on builders. D3-trivial 🧸 PR contains trivial changes in a runtime directory that do not require an audit. T4-parachains_engineering This PR/Issue is related to Parachains performance, stability, maintenance.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants