chore(metrics): generate internal metric documentation from Rust source#25460
Open
thomasqueirozb wants to merge 46 commits into
Open
chore(metrics): generate internal metric documentation from Rust source#25460thomasqueirozb wants to merge 46 commits into
thomasqueirozb wants to merge 46 commits into
Conversation
…rable macro to support deprecated = "..." on enum variants
…ripped tag descriptions
…ags in Rust, eliminate enum metric blocks from internal_metrics.cue
…al_metrics.cue is now metadata-only
…and compile-time constants
…or inline tag shapes
…ck, remove CUE tag helpers
…ally dropped from internal_metrics.cue
…tags CUE reference
…r to use generated metrics
…mes' into thomasqueirozb/25374-metric-name-docs
Contributor
|
Your preview site for the vector.dev will be ready in a few minutes, please allow time for it to build. Heres your preview link: |
Contributor
|
Your preview site for the VRL Playground will be ready in a few minutes, please allow time for it to build. Heres your preview link: |
Contributor
|
Your preview site for the Rust Doc will be ready in a few minutes, please allow time for it to build. Heres your preview link: |
9 tasks
Member
Author
|
@vectordotdev/documentation These are the additions which should be reviewed:
All other metrics are pre-existing. |
joepeeples
approved these changes
May 19, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Implements #25374: internal metric documentation is now fully generated from Rust source rather than manually maintained in CUE.
website/cue/reference/components/sources/internal_metrics.cueis now metadata-only and all metric output definitions come from the generated file.CounterName,HistogramName,GaugeNameinlib/vector-common/src/internal_event/metric_name.rscontain all information needed to generate internal metrics.src/generate_schema.rsinjects_metric_schemas: {counters, histograms, gauges}into the schema JSON produced byvector generate-schema.vdev build component-docscreateswebsite/cue/reference/generated/internal_metric_descriptions.cuefrom the schema.Vector configuration
NA
How did you test this PR?
make generate-component-docspasses.cargo check --workspace --no-default-featurespasses.make check-clippypasses.The following script compares
docs.jsonbetweenmasterand this branch to verify metric fidelity (124 shared metrics are fully equal after normalization; 3 intentional changes noted):verify_metrics.py
Output
The 3 differences are intentional: two grammar fixes (
collecting of→collecting,a HTTP→an HTTP) and one type correction (open_files:counter→gauge).Change Type
Is this a breaking change?
Does this PR include user facing changes?
no-changeloglabel to this PR.References