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

NodeVersion tracer for providing metrics #5764

Merged
merged 5 commits into from
May 23, 2024
Merged

Conversation

jutaro
Copy link
Contributor

@jutaro jutaro commented Apr 9, 2024

This adds a new trace message, which adds new metrics. Here is an example of what it provides:

cardano_build_info {
, version = "8.10.0"
, version_major="8"
, version_minor="10"
, version_patch="0"
, revision="fd7eb00d1697b0c6eb7f3e3d0ad6e94fcc5caa63"
, compiler_name="ghc"
, compiler_version="8.10"
, compiler_version_major="8"
, compiler_version_minor="10"
, architecture="x86_64"
, os_name="linux" 
} 1 

NB in the actual Prometheus output, this is 1 line only; newlines have been inserted here for readability only.

Additionally, it provided an alternative representation of the same data as trace messages for both machines and humans. Here are examples of how the data will be represented:

Machine Trace Message:
{"at":"2024-04-08T12:30:08.89384608Z","ns":"Version.NodeVersion","data":{"applicationName":"cardano-node","applicationVersion":"8.10.0","architecture":"x86_64","compilerName":"ghc","compilerVersion":"8.10","gitRevision":"f3fabe88bfc83f5e9c2a9d7af2293857cd8212c3","osName":"linux"},"sev":"Info","thread":"5","host":"deusXmachina"}

Human Trace Message:
[2024-04-08 13:46:26.5169Z]deusXmachina:Version.NodeVersion cardano-node 8.10.0 git rev f3fabe8 - linux-x86_64 - ghc-8.10

@jutaro jutaro force-pushed the jutaro/prometheus-types branch 2 times, most recently from fd7eb00 to 0ad9399 Compare April 22, 2024 09:56
@jutaro jutaro marked this pull request as ready for review April 22, 2024 13:04
@jutaro jutaro requested review from a team as code owners April 22, 2024 13:04
Copy link
Contributor

@manveru manveru left a comment

Choose a reason for hiding this comment

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

This looks like a really nice improvement, thank you!

@NadiaYvette
Copy link
Contributor

This will be great to have! I've had some (thankfully local) runs I've had to re-run because I lost track of which compiler was used for it.

cabal.project Outdated Show resolved Hide resolved
@jutaro jutaro force-pushed the jutaro/prometheus-types branch 3 times, most recently from e818219 to 2e2f5db Compare May 15, 2024 10:27
Copy link
Contributor

@mgmeier mgmeier left a comment

Choose a reason for hiding this comment

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

Additionally

  1. please add full namespace to
BlockForgingUpdate b -> sendEKGDirectInt ekgDirect' "forging_enabled"
  1. changelog entry / minor version bump for trace-dispatcher

cardano-node/src/Cardano/Node/Run.hs Outdated Show resolved Hide resolved
cardano-node/src/Cardano/Tracing/Tracers.hs Outdated Show resolved Hide resolved
Copy link
Contributor

@mgmeier mgmeier left a comment

Choose a reason for hiding this comment

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

Thanks @jutaro , great work, and very useful.

@mgmeier mgmeier added this pull request to the merge queue May 23, 2024
Merged via the queue into master with commit 3d5df51 May 23, 2024
27 of 29 checks passed
@mgmeier mgmeier deleted the jutaro/prometheus-types branch May 23, 2024 17:49
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.

4 participants