[k8s] Improve *.cpu.usage description#3931
Open
ChrsMark wants to merge 1 commit into
Open
Conversation
Pull request dashboard statusStatus last refreshed: 2026-07-25 10:12:41 UTC.
This automated status or its linked feedback items may be incorrect. If something looks wrong, please report it with the result you expected. |
Signed-off-by: ChrsMark <chrismarkou92@gmail.com>
ChrsMark
force-pushed
the
fix_cpu_usage_desc
branch
from
July 24, 2026 08:03
596708a to
38240b4
Compare
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.
Related to #2418
Changes
After the relevant discussions at #2418, the @open-telemetry/semconv-k8s-approvers group decided to switch the implementation detail of how the
*.cpu.usagemetrics are populated.Instead of deriving them directly from the Kubelet Stat's API and the UsageNanoCores in particular, the group decided that populating this metric on the fly, using the
usageCores = (cpuTimeEnd - cpuTimeStart) / elapsedSecondsformula, is more accurate. Calculating this metric using the actual scraping interval is more accurate and correct than relying on the fixed interval based on which the Kubelet derived metric is calculated (as proved at #2418 (comment)).This is also in alignment with the description of:
(Note that
utilization = usage / limit)The implementation switch is already in place behind a feature gate pair, introduced in the Collector by open-telemetry/opentelemetry-collector-contrib#49499.
This change is not a breaking change since the formula and concept for these metrics remain the same, with only the implementation detail being changed.
Merge requirement checklist
/cc @open-telemetry/semconv-k8s-approvers @jmmcorreia
Footnotes
Yes, I can answer maintainer questions about the content of this PR without using AI. ↩