Skip to content

update kubernetes to v1.37.0 - #14051

Merged
mikebrow merged 4 commits into
containerd:mainfrom
mikebrow:move-kubernetes-up-to-v1.37
Aug 27, 2026
Merged

mikebrow merged 4 commits into
containerd:mainfrom
mikebrow:move-kubernetes-up-to-v1.37

Conversation

@mikebrow

Copy link
Copy Markdown
Member

kubernetes' 1.37 release is out time to move up

Copilot AI lite review requested due to automatic review settings August 27, 2026 00:24
@github-project-automation github-project-automation Bot moved this to Needs Triage in Pull Request Review Aug 27, 2026
@mikebrow
mikebrow requested a review from dims August 27, 2026 00:24
@mikebrow mikebrow added this to the 2.4 milestone Aug 27, 2026
@mikebrow mikebrow added area/cri Container Runtime Interface (CRI) dependencies Pull requests that update a dependency file target/kubernetes/v1.37 labels Aug 27, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR vendors the Kubernetes 1.37 (k8s.io/* v0.37.0) dependency set into containerd, updating the CRI/client-go/apimachinery stacks and related third-party libraries to the versions shipped with that Kubernetes release.

Changes:

  • Bump Kubernetes module versions (k8s.io/api/apimachinery/client-go/cri-*) and refresh vendor/ accordingly.
  • Pull in updated structured-merge-diff behavior (managedFields JSON parsing, reflection caching) and JSON/CBOR/protobuf serializer improvements.
  • Update CRI client and CRI API surface (builder-style constructors, new pod checkpoint/restore RPCs) and client-go metrics registration behavior.

Reviewed changes

Copilot reviewed 1 out of 82 changed files in this pull request and generated no comments.

Show a summary per file
File Description
go.mod Bump k8s.io/* and related deps (e.g., fxamacker/cbor, structured-merge-diff).
vendor/modules.txt Vendor manifest updated to new module versions.
vendor/sigs.k8s.io/structured-merge-diff/v6/value/value.go Detect trailing data when parsing managedFields JSON.
vendor/sigs.k8s.io/structured-merge-diff/v6/value/reflectcache.go Add error-capable unstructured converter path; update reflection checks.
vendor/sigs.k8s.io/structured-merge-diff/v6/value/jsontagutil.go Align JSON tag handling with encoding/json behavior.
vendor/sigs.k8s.io/structured-merge-diff/v6/value/allocator.go Generic freelist allocator; clear references on Free().
vendor/k8s.io/utils/ptr/OWNERS Vendor OWNERS metadata update.
vendor/k8s.io/cri-client/pkg/remote_runtime.go Introduce builder API; add CheckpointPod/RestorePod client calls.
vendor/k8s.io/cri-client/pkg/remote_image.go Introduce builder API; tracer-provider default/opt-out behavior.
vendor/k8s.io/cri-api/pkg/apis/services.go Extend PodSandboxManager interface for checkpoint/restore.
vendor/k8s.io/cri-api/pkg/apis/runtime/v1/api.proto Add CheckpointPod/RestorePod RPCs; mount_options fields; signal enum rename.
vendor/k8s.io/cri-api/pkg/apis/runtime/v1/api_grpc.pb.go Regenerate gRPC bindings for new RPCs and generator version.
vendor/k8s.io/client-go/transport/transport.go Ensure metrics are registered when constructing transports.
vendor/k8s.io/client-go/transport/spdy/spdy.go Add lints suppression for non-structured logging cases.
vendor/k8s.io/client-go/transport/OWNERS Vendor OWNERS metadata update.
vendor/k8s.io/client-go/tools/metrics/metrics.go Add EnsureRegistered + deferred registration hook; bugfix in Register().
vendor/k8s.io/client-go/rest/transport.go Ensure metrics are registered when building transport config.
vendor/k8s.io/client-go/rest/request.go Avoid wrapping context cancellation/deadline errors from rate limiter.
vendor/k8s.io/client-go/rest/OWNERS Vendor OWNERS metadata update.
vendor/k8s.io/client-go/rest/config.go Ensure metrics are registered before creating REST clients.
vendor/k8s.io/client-go/rest/client.go Ensure metrics are registered in NewRESTClient.
vendor/k8s.io/client-go/plugin/pkg/client/auth/exec/exec.go Ensure metrics are registered before authenticator construction.
vendor/k8s.io/client-go/pkg/apis/clientauthentication/v1beta1/zz_generated.conversion.go Optimize conversions via unsafe struct copy.
vendor/k8s.io/client-go/pkg/apis/clientauthentication/v1beta1/types.go Update TypeMeta json tag encoding expectations.
vendor/k8s.io/client-go/pkg/apis/clientauthentication/v1/zz_generated.conversion.go Optimize conversions via unsafe struct copy.
vendor/k8s.io/client-go/pkg/apis/clientauthentication/v1/types.go Update TypeMeta json tag encoding expectations.
vendor/k8s.io/apimachinery/pkg/util/validation/ip.go Add lints suppression comments around “should not be reached” logs.
vendor/k8s.io/apimachinery/pkg/util/validation/field/errors.go Add short-circuit fields and marker helpers to validation errors.
vendor/k8s.io/apimachinery/pkg/util/validation/field/error_matcher.go Add short-circuit-aware matching + path descendant logic.
vendor/k8s.io/apimachinery/pkg/util/intstr/intstr.go Add lints suppression comment for debug-stack logging path.
vendor/k8s.io/apimachinery/pkg/runtime/types.go Update embedded TypeMeta json tags and Unknown.TypeMeta tag.
vendor/k8s.io/apimachinery/pkg/runtime/swagger_doc_generator.go Make parsing return aggregate errors; robust struct tag unquoting.
vendor/k8s.io/apimachinery/pkg/runtime/serializer/versioning/versioning.go Add lints suppression and allocator logging note.
vendor/k8s.io/apimachinery/pkg/runtime/serializer/protobuf/protobuf.go Reduce per-item allocations for protobuf headers; allocator logging.
vendor/k8s.io/apimachinery/pkg/runtime/serializer/protobuf/collections.go Remove per-varint allocations; reuse header scratch.
vendor/k8s.io/apimachinery/pkg/runtime/serializer/json/json.go Add lints suppression comment for “should not be reached” fatal.
vendor/k8s.io/apimachinery/pkg/runtime/serializer/json/collections.go Stream encoder with buffer reuse; updated TypeMeta tag checks.
vendor/k8s.io/apimachinery/pkg/runtime/serializer/cbor/internal/modes/encode.go Track deterministic encoding on modes.
vendor/k8s.io/apimachinery/pkg/runtime/serializer/cbor/collections.go Add streaming CBOR encoding for list-like objects.
vendor/k8s.io/apimachinery/pkg/runtime/serializer/cbor/cbor.go Enable streaming collections encoding; encode self-described CBOR early.
vendor/k8s.io/apimachinery/pkg/runtime/scheme.go Change validation options type to map; add HasValidationFunc.
vendor/k8s.io/apimachinery/pkg/runtime/helper.go Adjust UseNondeterministicEncoding signature; adapter now embeds Decoder.
vendor/k8s.io/apimachinery/pkg/runtime/generated.proto Update embedded TypeMeta json tags in comments.
vendor/k8s.io/apimachinery/pkg/runtime/fieldinfo_127.go go1.27 build: tag-driven inline detection helper.
vendor/k8s.io/apimachinery/pkg/runtime/fieldinfo_126.go !go1.27 build: inline detection stub.
vendor/k8s.io/apimachinery/pkg/runtime/converter.go JSON tag lookup changes; uint overflow helper extracted.
vendor/k8s.io/apimachinery/pkg/runtime/conversion.go Remove JSONKeyMapper helper from this file.
vendor/k8s.io/apimachinery/pkg/runtime/codec.go Add lints suppression comment for fatal marshaling paths.
vendor/k8s.io/apimachinery/pkg/labels/selector.go Switch to structured klog for ParseInt failures; lint suppression notes.
vendor/k8s.io/apimachinery/pkg/conversion/queryparams/convert.go Use Tag.Lookup for json tag presence correctness.
vendor/k8s.io/apimachinery/pkg/apis/meta/v1/unstructured/helpers.go Add lints suppression comment for fatal marshaling paths.
vendor/k8s.io/apimachinery/pkg/apis/meta/v1/types.go Update embedded TypeMeta json tags; add new alpha markers/annotations.
vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto Mirror new alpha markers/annotations in generated proto comments.
vendor/k8s.io/apimachinery/pkg/api/validate/content/kube.go Add IsPrefixedLabelKey helper.
vendor/k8s.io/apimachinery/pkg/api/resource/quantity.go Add QuantityPtrEqual helper.
vendor/k8s.io/apimachinery/pkg/api/operation/operation.go Change Options to map[string]bool; HasOption returns (enabled, defined).
vendor/k8s.io/apimachinery/pkg/api/meta/restmapper.go Add RESTMapperWithContext method implementations on DefaultRESTMapper.
vendor/k8s.io/apimachinery/pkg/api/meta/priority.go Add PriorityRESTMapperWithContext and context-aware wrappers.
vendor/k8s.io/apimachinery/pkg/api/meta/multirestmapper.go Add MultiRESTMapperWithContext and context-aware wrappers.
vendor/k8s.io/apimachinery/pkg/api/meta/meta.go Add lint suppression notes for “should not happen” logs.
vendor/k8s.io/apimachinery/pkg/api/meta/interfaces.go Introduce RESTMapperWithContext + resettable-with-context wrappers.
vendor/k8s.io/api/core/v1/zz_generated.prerelease-lifecycle.go Remove lifecycle stub for removed type(s).
vendor/k8s.io/api/core/v1/zz_generated.model_name.go Add new model names; remove model name for removed type(s).
vendor/k8s.io/api/core/v1/zz_generated.deepcopy.go Regenerate deep-copies for new/changed API types.
vendor/k8s.io/api/core/v1/register.go Stop registering removed type(s) in scheme known types.
vendor/github.com/fxamacker/cbor/v2/valid.go CBOR validation bugfixes and lint annotations.
vendor/github.com/fxamacker/cbor/v2/structfields.go Refactor field metadata; keyasint normalization and dedupe changes.
vendor/github.com/fxamacker/cbor/v2/stream.go Indefinite-length encoding validations; avoid returning shared nil slice.
vendor/github.com/fxamacker/cbor/v2/simplevalue.go Add lint annotation for safe narrowing conversion.
vendor/github.com/fxamacker/cbor/v2/README.md Update release notes to v2.9.1.
vendor/github.com/fxamacker/cbor/v2/encode.go Encoding improvements; new TimeRFC3339NanoUTC; sorting comparator strictness.
vendor/github.com/fxamacker/cbor/v2/diagnose.go Defensive checks; lint annotations; UTF-8 handling tweak.
vendor/github.com/fxamacker/cbor/v2/decode_map_utils.go New helpers for struct-field lookup and dup-key handling.
vendor/github.com/fxamacker/cbor/v2/cache.go Refactor decoding/encoding struct caches; separate encoding/decoding fields.
vendor/github.com/fxamacker/cbor/v2/.golangci.yml Update golangci-lint config format and enabled linters/formatters.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@mikebrow

Copy link
Copy Markdown
Member Author

have to fix the Signal_ -> Signal_SIGNAL changes that dropped into cri vendor

@mikebrow
mikebrow marked this pull request as draft August 27, 2026 00:59
Copilot AI review requested due to automatic review settings August 27, 2026 13:41

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 8 out of 89 changed files in this pull request and generated 1 comment.

Copilot AI review requested due to automatic review settings August 27, 2026 14:05
@mikebrow
mikebrow force-pushed the move-kubernetes-up-to-v1.37 branch from bba5f83 to 1dd6201 Compare August 27, 2026 14:05
@mikebrow

Copy link
Copy Markdown
Member Author

#13603
cc @sreeram-venkitesh

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 8 out of 89 changed files in this pull request and generated 2 comments.

@mikebrow
mikebrow force-pushed the move-kubernetes-up-to-v1.37 branch from 1dd6201 to f0a7a69 Compare August 27, 2026 14:13
Copilot AI review requested due to automatic review settings August 27, 2026 14:46
@sreeram-venkitesh

Copy link
Copy Markdown
Contributor

@mikebrow LGTM from my end, thanks for addressing the persisted stop signals 🙇🏼

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 10 out of 91 changed files in this pull request and generated 2 comments.

Suppressed comments (1)

internal/cri/server/container_stop_signal.go:31

  • criSignalToOCIStopSignal currently returns stop-signal strings with the CRI enum name prefix (e.g. "SIGNAL_SIGTERM"). That prefix is not a valid OCI/posix signal name and requires downstream callers to strip it defensively. Normalizing here (dropping "SIGNAL_" before PLUS/MINUS normalization) keeps persisted stop-signal values stable ("SIGTERM", "SIGRTMIN+1", etc.) and avoids leaking proto enum naming into runtime behavior.
func criSignalToOCIStopSignal(signal runtime.Signal) (string, error) {
	if signal == runtime.Signal_SIGNAL_RUNTIME_DEFAULT {
		return "", nil
	}

@mikebrow

mikebrow commented Aug 27, 2026 •

Copy link
Copy Markdown
Member Author

@mikebrow LGTM from my end, thanks for addressing the persisted stop signals 🙇🏼

** corrected text, no cherry pick required as the modified change in the cri contract was only for the string value of the signal, the config signals received in container create come over as the int value of the signal.. which has not changed... thus older releases of containerd should work with this modified version of the kubelet so long as the vendor for cri is not updated to v0.37

note the strip "SIGNAL_" in stop container on the call to moby's parse... figured it's quick so call it as is then again sans "SIGNAL_" for those cases

Copilot AI review requested due to automatic review settings August 27, 2026 17:39

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 10 out of 91 changed files in this pull request and generated no new comments.

Suppressed comments (1)

internal/cri/server/container_stop_test.go:104

  • Test expectations for criSignalToOCIStopSignal use the CRI enum prefix ("SIGNAL_") even though criSignalToOCIStopSignal now trims that prefix and returns POSIX-style stop-signal strings (e.g. "SIGTERM", "SIGRTMIN+1"). As written, these assertions will fail and they also conflict with the stop-signal strings persisted into container metadata.
		{name: "runtime default", signal: runtime.Signal_SIGNAL_RUNTIME_DEFAULT, expectedSignal: ""},
		{name: "standard signal", signal: runtime.Signal_SIGNAL_SIGTERM, expectedSignal: "SIGNAL_SIGTERM"},
		{name: "rtmin plus", signal: runtime.Signal_SIGNAL_SIGRTMINPLUS1, expectedSignal: "SIGNAL_SIGRTMIN+1"},
		{name: "rtmax minus", signal: runtime.Signal_SIGNAL_SIGRTMAXMINUS1, expectedSignal: "SIGNAL_SIGRTMAX-1"},

Copilot AI review requested due to automatic review settings August 27, 2026 17:49
@mikebrow
mikebrow force-pushed the move-kubernetes-up-to-v1.37 branch from ac6dd9b to dc99289 Compare August 27, 2026 17:49

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 10 out of 91 changed files in this pull request and generated no new comments.

Suppressed comments (1)

internal/cri/server/container_status_test.go:293

  • TestToCRISignal only exercises inputs that already include the CRI enum prefix ("SIGNAL_..."). In this codebase, container metadata persists OCI-style stop-signal strings (e.g. "SIGTERM", "SIGRTMIN+1") via criSignalToOCIStopSignal (see internal/cri/server/container_create.go:331-339), and toCRISignal has explicit compatibility logic for those non-prefixed values. Adding a couple of non-prefixed cases here would prevent regressions in the legacy/persisted stop-signal path.
		{input: "SIGNAL_SIGABRT", expected: runtime.Signal_SIGNAL_SIGABRT},
		{input: "SIGNAL_SIGALRM", expected: runtime.Signal_SIGNAL_SIGALRM},
		{input: "SIGNAL_SIGBUS", expected: runtime.Signal_SIGNAL_SIGBUS},
		{input: "SIGNAL_SIGCHLD", expected: runtime.Signal_SIGNAL_SIGCHLD},
		{input: "SIGNAL_SIGCLD", expected: runtime.Signal_SIGNAL_SIGCLD},

Copilot AI review requested due to automatic review settings August 27, 2026 20:24
@mikebrow
mikebrow force-pushed the move-kubernetes-up-to-v1.37 branch from dc99289 to 67336d7 Compare August 27, 2026 20:24
@mikebrow

Copy link
Copy Markdown
Member Author

all green rebasing

@github-project-automation github-project-automation Bot moved this from Needs Triage to Review In Progress in Pull Request Review Aug 27, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 10 out of 91 changed files in this pull request and generated 1 comment.

Suppressed comments (1)

internal/cri/server/container_status_test.go:343

  • Same as the SIGRTMIN cases: these SIGRTMAX inputs include '-' (e.g. "SIGNAL_SIGRTMAX-14") but the generated enum names use MINUS (e.g. "SIGNAL_SIGRTMAXMINUS14" in vendor/k8s.io/cri-api/pkg/apis/runtime/v1/api.pb.go:523). Prefer the canonical names here so the test exercises the actual runtime.Signal_value mapping directly.
		{input: "SIGNAL_SIGRTMAX-14", expected: runtime.Signal_SIGNAL_SIGRTMAXMINUS14},
		{input: "SIGNAL_SIGRTMAX-13", expected: runtime.Signal_SIGNAL_SIGRTMAXMINUS13},
		{input: "SIGNAL_SIGRTMAX-12", expected: runtime.Signal_SIGNAL_SIGRTMAXMINUS12},
		{input: "SIGNAL_SIGRTMAX-11", expected: runtime.Signal_SIGNAL_SIGRTMAXMINUS11},
		{input: "SIGNAL_SIGRTMAX-10", expected: runtime.Signal_SIGNAL_SIGRTMAXMINUS10},

Comment on lines +324 to +338
{input: "SIGNAL_SIGRTMIN+1", expected: runtime.Signal_SIGNAL_SIGRTMINPLUS1},
{input: "SIGNAL_SIGRTMIN+2", expected: runtime.Signal_SIGNAL_SIGRTMINPLUS2},
{input: "SIGNAL_SIGRTMIN+3", expected: runtime.Signal_SIGNAL_SIGRTMINPLUS3},
{input: "SIGNAL_SIGRTMIN+4", expected: runtime.Signal_SIGNAL_SIGRTMINPLUS4},
{input: "SIGNAL_SIGRTMIN+5", expected: runtime.Signal_SIGNAL_SIGRTMINPLUS5},
{input: "SIGNAL_SIGRTMIN+6", expected: runtime.Signal_SIGNAL_SIGRTMINPLUS6},
{input: "SIGNAL_SIGRTMIN+7", expected: runtime.Signal_SIGNAL_SIGRTMINPLUS7},
{input: "SIGNAL_SIGRTMIN+8", expected: runtime.Signal_SIGNAL_SIGRTMINPLUS8},
{input: "SIGNAL_SIGRTMIN+9", expected: runtime.Signal_SIGNAL_SIGRTMINPLUS9},
{input: "SIGNAL_SIGRTMIN+10", expected: runtime.Signal_SIGNAL_SIGRTMINPLUS10},
{input: "SIGNAL_SIGRTMIN+11", expected: runtime.Signal_SIGNAL_SIGRTMINPLUS11},
{input: "SIGNAL_SIGRTMIN+12", expected: runtime.Signal_SIGNAL_SIGRTMINPLUS12},
{input: "SIGNAL_SIGRTMIN+13", expected: runtime.Signal_SIGNAL_SIGRTMINPLUS13},
{input: "SIGNAL_SIGRTMIN+14", expected: runtime.Signal_SIGNAL_SIGRTMINPLUS14},
{input: "SIGNAL_SIGRTMIN+15", expected: runtime.Signal_SIGNAL_SIGRTMINPLUS15},
@mikebrow
mikebrow added this pull request to the merge queue Aug 27, 2026
Merged via the queue into containerd:main with commit 7e66a3f Aug 27, 2026
54 of 55 checks passed
@github-project-automation github-project-automation Bot moved this from Review In Progress to Done in Pull Request Review Aug 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/cri Container Runtime Interface (CRI) dependencies Pull requests that update a dependency file size/XXL target/kubernetes/v1.37

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

6 participants