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

CRI: add fields for pod level stats to satisfy the /stats/summary API #102789

Merged

Conversation

haircommander
Copy link
Contributor

@haircommander haircommander commented Jun 10, 2021

What type of PR is this?

/kind feature

What this PR does / why we need it:

Adds the necessary fields for the stats summary API to the CRI API, thus completing the first step of kubernetes/enhancements#2364

Which issue(s) this PR fixes:

Special notes for your reviewer:

Does this PR introduce a user-facing change?

none

Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.:

- [KEP]: https://github.com/kubernetes/enhancements/pull/2364

@k8s-ci-robot k8s-ci-robot added release-note-none Denotes a PR that doesn't merit a release note. kind/feature Categorizes issue or PR as related to a new feature. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. do-not-merge/needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. area/kubelet labels Jun 10, 2021
@k8s-ci-robot k8s-ci-robot added sig/node Categorizes an issue or PR as relevant to SIG Node. needs-priority Indicates a PR lacks a `priority/foo` label and requires one. and removed do-not-merge/needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. labels Jun 10, 2021
Comment on lines 1451 to 1464
// Stats pertaining to container logs usage of filesystem resources
// Logs.UsedBytes is the number of bytes used for the container logs.
FilesystemUsage logs = 5;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

while discussed in the KEP, it's unclear to me right now whether this is the correct direciton. the paths for ContainerStatsProviders and HostStatsProvider are quite different, and querying cadvisor for the size of a path on the host does seem out of scope of "container and pod level stats", even if they're logs.

finally, CRI doesn't think much about logs besides ensuring they're written.

@haircommander
Copy link
Contributor Author

/priority important-soon

@k8s-ci-robot k8s-ci-robot added priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release. and removed needs-priority Indicates a PR lacks a `priority/foo` label and requires one. labels Jun 10, 2021
@haircommander
Copy link
Contributor Author

/retest

@ehashman
Copy link
Member

/triage accepted

@k8s-ci-robot k8s-ci-robot added triage/accepted Indicates an issue or PR is ready to be actively worked on. and removed needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Jun 11, 2021
@bobbypage
Copy link
Member

/cc

@haircommander
Copy link
Contributor Author

I originally had thought we were moving to CRI v1 more quickly than we are. I've updated with the changes to v1alpha2 as well

@haircommander
Copy link
Contributor Author

updated kubernetes/enhancements#2812 and this with the review comments, excluding the PodSandboxAttributes->PodSandbox change, which I am not sold on :)

@bobbypage
Copy link
Member

Thanks for the updates. Make sense regarding keeping PodSandboxAttributes as it mirrors the existing ContainerStats model (i.e. ContainerAttributes message nested in ContainerStats).

@haircommander
Copy link
Contributor Author

missed a couple of comments, but I should be up to date now

@haircommander
Copy link
Contributor Author

/retest

Signed-off-by: Peter Hunt <pehunt@redhat.com>
Signed-off-by: Peter Hunt <pehunt@redhat.com>
@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jul 8, 2021
@bobbypage
Copy link
Member

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jul 8, 2021
@ehashman
Copy link
Member

ehashman commented Jul 8, 2021

/milestone v1.22

@k8s-ci-robot k8s-ci-robot added this to the v1.22 milestone Jul 8, 2021
Copy link
Member

@mikebrow mikebrow left a comment

Choose a reason for hiding this comment

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

LGTM

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: haircommander, mikebrow, mrunalp

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@JamesLaverack
Copy link
Member

Pending a decision on the exception request we are removing the milestone.

/milestone clear

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. area/kubelet cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/feature Categorizes issue or PR as related to a new feature. lgtm "Looks good to me", indicates that a PR is ready to be merged. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release. release-note-none Denotes a PR that doesn't merit a release note. sig/node Categorizes an issue or PR as relevant to SIG Node. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. triage/accepted Indicates an issue or PR is ready to be actively worked on.
Projects
Development

Successfully merging this pull request may close these issues.

9 participants