CRI: add cavieats about cgroup driver field

Signed-off-by: Peter Hunt <pehunt@redhat.com>
This commit is contained in:
Peter Hunt 2023-06-26 16:15:10 -04:00
parent d7797fbc61
commit d0952686f6
2 changed files with 30 additions and 0 deletions

View File

@ -9672,6 +9672,12 @@ func (m *RuntimeConfigResponse) GetLinux() *LinuxRuntimeConfiguration {
type LinuxRuntimeConfiguration struct {
// Cgroup driver to use
// Note: this field should not change for the lifecycle of the Kubelet,
// or while there are running containers.
// The Kubelet will not re-request this after startup, and will construct the cgroup
// hierarchy assuming it is static.
// If the runtime wishes to change this value, it must be accompanied by removal of
// all pods, and a restart of the Kubelet. The easiest way to do this is with a full node reboot.
CgroupDriver CgroupDriver `protobuf:"varint,1,opt,name=cgroup_driver,json=cgroupDriver,proto3,enum=runtime.v1.CgroupDriver" json:"cgroup_driver,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_sizecache int32 `json:"-"`
@ -10429,6 +10435,12 @@ type RuntimeServiceClient interface {
// ListPodSandboxMetrics gets pod sandbox metrics from CRI Runtime
ListPodSandboxMetrics(ctx context.Context, in *ListPodSandboxMetricsRequest, opts ...grpc.CallOption) (*ListPodSandboxMetricsResponse, error)
// RuntimeConfig returns configuration information of the runtime.
// A couple of notes:
// - The RuntimeConfigRequest object is not to be confused with the contents of UpdateRuntimeConfigRequest.
// The former is for having runtime tell Kubelet what to do, the latter vice versa.
// - It is the expectation of the Kubelet that these fields are static for the lifecycle of the Kubelet.
// The Kubelet will not re-request the RuntimeConfiguration after startup, and CRI implementations should
// avoid updating them without a full node reboot.
RuntimeConfig(ctx context.Context, in *RuntimeConfigRequest, opts ...grpc.CallOption) (*RuntimeConfigResponse, error)
}
@ -10815,6 +10827,12 @@ type RuntimeServiceServer interface {
// ListPodSandboxMetrics gets pod sandbox metrics from CRI Runtime
ListPodSandboxMetrics(context.Context, *ListPodSandboxMetricsRequest) (*ListPodSandboxMetricsResponse, error)
// RuntimeConfig returns configuration information of the runtime.
// A couple of notes:
// - The RuntimeConfigRequest object is not to be confused with the contents of UpdateRuntimeConfigRequest.
// The former is for having runtime tell Kubelet what to do, the latter vice versa.
// - It is the expectation of the Kubelet that these fields are static for the lifecycle of the Kubelet.
// The Kubelet will not re-request the RuntimeConfiguration after startup, and CRI implementations should
// avoid updating them without a full node reboot.
RuntimeConfig(context.Context, *RuntimeConfigRequest) (*RuntimeConfigResponse, error)
}

View File

@ -133,6 +133,12 @@ service RuntimeService {
rpc ListPodSandboxMetrics(ListPodSandboxMetricsRequest) returns (ListPodSandboxMetricsResponse) {}
// RuntimeConfig returns configuration information of the runtime.
// A couple of notes:
// - The RuntimeConfigRequest object is not to be confused with the contents of UpdateRuntimeConfigRequest.
// The former is for having runtime tell Kubelet what to do, the latter vice versa.
// - It is the expectation of the Kubelet that these fields are static for the lifecycle of the Kubelet.
// The Kubelet will not re-request the RuntimeConfiguration after startup, and CRI implementations should
// avoid updating them without a full node reboot.
rpc RuntimeConfig(RuntimeConfigRequest) returns (RuntimeConfigResponse) {}
}
@ -1819,6 +1825,12 @@ message RuntimeConfigResponse {
message LinuxRuntimeConfiguration {
// Cgroup driver to use
// Note: this field should not change for the lifecycle of the Kubelet,
// or while there are running containers.
// The Kubelet will not re-request this after startup, and will construct the cgroup
// hierarchy assuming it is static.
// If the runtime wishes to change this value, it must be accompanied by removal of
// all pods, and a restart of the Kubelet. The easiest way to do this is with a full node reboot.
CgroupDriver cgroup_driver = 1;
}