Repository navigation
feat: collect container requests/limits and pod QoS class - #6
Merged
Merged
Conversation
Requests and limits are normalized at the source: CPU to millicores, memory to bytes. Absent values stay nil — "not set" is a meaningful fact, distinct from zero. Pod QoS class is taken from status. Already covered by docs/security.md §8 (resource metrics, field minimization keeps spec.containers[].resources). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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.
Second collector slice — from metadata to resource data:
Containergains aResourcesstruct: CPU request/limit in millicores, memory request/limit in bytes — normalized at the source per ADR 0004 (resource units are the truth), no quantity strings downstream.nil, not zero: "not set" is itself a signal (BestEffort pods are prime finding candidates).PodInfogains the pod's QoS class from status.No security.md change needed: §8 already lists requests/limits under resource metrics and keeps
spec.containers[].resourcesin field minimization — the code catches up with the promise, not the other way around.Tests: unit coverage for full/partial/absent resource declarations (incl. init containers) on the fake clientset; e2e deployment now declares requests/limits and asserts the normalized numbers and QoS class against a real cluster. e2e verified locally on kind v1.36.1.
🤖 Generated with Claude Code