Commit Graph

12993 Commits

Author SHA1 Message Date
Kubernetes Prow Robot
d6c073990b Merge pull request #134623 from adrianmoisey/service-headless
Refactor 'Services should implement service.kubernetes.io/headless' test
2025-12-17 16:26:47 -08:00
bzsuni
2c811fdd3a etcd: Update etcd to v3.6.6
Signed-off-by: bzsuni <bingzhe.sun@daocloud.io>
2025-12-08 05:37:15 +00:00
Angelos Kolaitis
03066850f6 remove TestEtcdSupportedVersionLength, no longer relevant
Signed-off-by: Angelos Kolaitis <neoaggelos@gmail.com>
2025-12-03 13:19:09 +02:00
Angelos Kolaitis
aa54ffa485 fix etcd versions after rotation
Signed-off-by: Angelos Kolaitis <neoaggelos@gmail.com>
2025-12-03 13:15:49 +02:00
Angelos Kolaitis
4a944d1a3f add skew -2 version in SupportedEtcdVersion
Signed-off-by: Angelos Kolaitis <neoaggelos@gmail.com>
2025-12-03 13:11:10 +02:00
Adrian Moisey
002c85b218 Tweak the informer for Services
It no longer filters out Services with the v1.IsHeadlessService
label as that is left for EndpointSlices
2025-11-17 08:39:38 +02:00
Kubernetes Prow Robot
173523550a Merge pull request #135092 from MoonYoung02/kube-proxy-fix-contextual-logging
Switch kube-proxy/server.go to context-aware logging APIs (HandleErrorWithContext, UntilWithContext)
2025-11-07 13:18:52 -08:00
Kubernetes Prow Robot
f38a61181c Merge pull request #133968 from yashsingh74/bump-coredns-1.12.4
Update coredns to v1.13.1
2025-11-06 20:38:54 -08:00
Richa Banker
8f2c0a9a60 kube-apiserver: Enable peer proxy and peer-aggregated discovery
Wire up peer proxy infrastructure in kube-apiserver:
- Add UnknownVersionInteroperabilityProxy feature gate
- Configure peer proxy with identity lease selectors
- Register CRD and APIService informers with exclusion filters
- Start peer discovery sync and GV cleanup workers

Includes extractors for CRDs and APIServices to identify which
GroupVersions should be excluded from peer discovery.

Part of KEP-4020: Unknown Version Interoperability Proxy
2025-11-06 12:48:19 -08:00
MoonYoung02
f86a456ea3 Switch kube-proxy/server.go to context-aware logging APIs (HandleErrorWithContext, UntilWithContext) 2025-11-07 00:56:29 +09:00
Maciej Skoczeń
9639274676 api: Create Workload API 2025-11-06 09:36:43 +00:00
Kubernetes Prow Robot
50b4bcbab5 Merge pull request #134210 from yliaog/admit_quota
DRA extended resource quota
2025-11-06 00:42:53 -08:00
Kubernetes Prow Robot
37934c5c26 Merge pull request #134890 from SataQiu/kubeadm-support-etcd-http-endpoints
kubeadm: support specifying HTTP endpoints for external etcd, allowing users to separate gRPC and HTTP traffic for etcd
2025-11-05 22:48:50 -08:00
yliao
870062df4f adjusts DRA extended resource quota to include devices usages from regular resource claims 2025-11-05 23:24:24 +00:00
Kubernetes Prow Robot
799572b8db Merge pull request #134711 from mortent/SimpleScoringForPrioritizedList
DRA: Add scoring for Prioritized List feature
2025-11-05 12:36:51 -08:00
Kubernetes Prow Robot
189b0052a5 Merge pull request #135100 from HirazawaUi/fix-3257
Fix potential dryrun failure when NodeLocalCRISocket reaches GA
2025-11-05 11:26:57 -08:00
Morten Torkildsen
fbfeb33231 DRA: Add scoring for Prioritized List feature 2025-11-05 17:18:38 +00:00
HirazawaUi
79dc7908ff Fix potential dryrun failure when NodeLocalCRISocket reaches GA 2025-11-05 23:46:03 +08:00
Kubernetes Prow Robot
5fd9cefd95 Merge pull request #134995 from yongruilin/flagz-kk-structure
[KEP-4828] Flagz versioned structured response
2025-11-04 19:02:04 -08:00
Kubernetes Prow Robot
c1a6a3ca71 Merge pull request #134152 from pohly/dra-device-taints-1.35
DRA: device taints: new ResourceSlice API, new features
2025-11-04 15:32:07 -08:00
Patrick Ohly
f4a453389d DRA device taint eviction: configurable number of workers
It might never be necessary to change the default, but it is hard to be sure.
It's better to have the option, just in case.
2025-11-04 21:57:24 +01:00
yongruilin
2422bc0bb8 feat: Implement structured /flagz endpoint 2025-11-04 19:45:30 +00:00
Kubernetes Prow Robot
a058cf788a Merge pull request #134624 from yt2985/podcertificates-beta
Promote Pod Certificates feature to beta
2025-11-04 11:42:12 -08:00
SataQiu
a079e1ed25 kubeadm: add 'HTTPEndpoints' field to 'ClusterConfiguration.Etcd.ExternalEtcd' that can be used to configure the HTTP endpoints for etcd communication 2025-11-04 22:12:19 +08:00
Lukasz Szaszkiewicz
257ff6edcd kubelet/app/server_bootstrap_test: fix Test_buildClientCertificateManager 2025-11-04 09:59:11 +01:00
Kubernetes Prow Robot
4e8499740e Merge pull request #134985 from swatisehgal/node-cm-ctx-logging-migration
node: cm: migrate container manager to contextual logging
2025-11-03 09:34:12 -08:00
Kubernetes Prow Robot
5e2ad84f67 Merge pull request #134906 from carlory/fix-kubeadm-3229
kubeadm: added container runtime version check to preflight
2025-11-02 23:36:04 -08:00
tinatingyu
59e075e8d3 Promote PodCertificateRequests to v1beta1 2025-11-02 05:33:44 +00:00
Kubernetes Prow Robot
f66d1a9418 Merge pull request #133779 from carlory/kubelet-cleanup-pod-infra-container-image
Remove deprecated pod-infra-container-image flag
2025-10-31 10:10:07 -07:00
Kubernetes Prow Robot
299a4fc2d2 Merge pull request #134847 from prometherion/feat/kubeadm-dns-signature
refactor(kubeadm): including dns addon version to signature
2025-10-31 03:52:05 -07:00
carlory
b3415bfdfe kubeadm: added container runtime version check to preflight
Co-authored-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: carlory <baofa.fan@daocloud.io>
2025-10-31 09:51:01 +08:00
Kubernetes Prow Robot
9efb7ee538 Merge pull request #134313 from richabanker/statusz-structured
[KEP:4827] Structured statusz
2025-10-30 13:16:10 -07:00
Siyuan Zhang
67143028e7 Add --min-compatibility flag.
Signed-off-by: Siyuan Zhang <sizhang@google.com>
2025-10-30 13:36:38 -05:00
Swati Sehgal
05f67d834a node: cm: migrate container manager to contextual logging
This commit migrates the container manager package to use
contextual logging.

This follows the contextual logging migration pattern where:
- Logger is passed from the boundary down to implementations
- klog.TODO() is used at call sites where context is not yet available
- Functions with context.Context extract logger via klog.FromContext(ctx)
- klog.InfoS/ErrorS/V().InfoS calls are replaced with logger.Info/Error/V().Info
- Sub-managers receive proper logger context from their callers

Some call sites still use klog.TODO() as placeholders, with TODO
comments indicating these will be replaced with proper contextual loggers
as the migration continues upward through the call stack.

Test/fake implementations use klog.Background() which is the appropriate
choice for test code where no real context is available.

Mock file updates (pkg/kubelet/cm/testing/mocks.go) were done manually
due to mockery tool incompatibility with Go 1.25 and will be committed
separately with an explanation.

Key changes:

1. PodContainerManager and ContainerManager interface updates:
   - PodContainerManager.EnsureExists: add logger parameter
   - PodContainerManager.Destroy: add logger parameter
   - PodContainerManager.ReduceCPULimits: add logger parameter
   - PodContainerManager.SetPodCgroupConfig: add logger parameter
   - ContainerManager.UpdateQOSCgroups: add logger parameter
   - Update all implementations (Linux, Windows, stub, noop, fake)

2. Helper function updates:
   - GetKubeletContainer: add logger parameter (Linux and unsupported platforms)
   - Update cmd/kubelet/app/server.go to pass logger to GetKubeletContainer
   - Comment out type assertion in helpers.go due to signature change

3. Cgroup manager contextual logging:
   - CgroupManager interface methods updated to accept logger:
     * Destroy: add logger parameter
     * ReduceCPULimits: add logger parameter
     * SetCgroupConfig: add logger parameter
   - Update cgroupCommon and unsupportedCgroupManager implementations
   - Migrate klog.InfoS/V().InfoS calls to logger.Info/V().Info

4. Container manager implementation updates:
   - Extract logger from context in NewContainerManager() and Start()
   - Pass logger to sub-managers (deviceManager, topologyManager)
   - Update DRA manager initialization to use logger from context
   - Migrate klog.InfoS/ErrorS to logger.Info/Error throughout

5. Call sites updated with TODO comments:
   - pkg/kubelet/kubelet.go: UpdateQOSCgroups, EnsureExists
   - pkg/kubelet/kubelet_pods.go: UpdateQOSCgroups, ReduceCPULimits, Destroy
   - pkg/kubelet/kuberuntime/kuberuntime_manager.go: SetPodCgroupConfig
   - pkg/kubelet/kuberuntime/kuberuntime_manager_test.go: test expectations

Most call sites currently use klog.TODO() as placeholders, with TODO
comments indicating these will be replaced with proper contextual loggers
as the migration continues upward through the call stack.

Test/fake implementations use klog.Background() which is the appropriate
choice for test code where no real context is available.

Mock file updates (pkg/kubelet/cm/testing/mocks.go) were done manually
due to mockery tool incompatibility with Go 1.25 and will be committed
separately with an explanation.

Signed-off-by: Swati Sehgal <swsehgal@redhat.com>
2025-10-30 18:34:03 +00:00
Richa Banker
c1a95eb7e2 Structured statusz 2025-10-30 10:39:52 -07:00
Kubernetes Prow Robot
3ec2d82da5 Merge pull request #134784 from michaelasp/svm_beta2
SVM: bump the API to beta, remove unused fields
2025-10-29 13:56:02 -07:00
Michael Aspinwall
3b72759d1b Update SVM to Beta
Co-authored-by: Stanislav Láznička <stlaz.devel@proton.me>
2025-10-29 19:36:11 +00:00
Kubernetes Prow Robot
110408060c Merge pull request #134542 from hoskeri/clean-loopback-clients
Drop loopback clients if unused
2025-10-28 09:10:02 -07:00
Kubernetes Prow Robot
0517fc4126 Merge pull request #134866 from neolit123/1.35-kubeadm-drop-etcd-extra-versions
kubeadm: improve the etcd version mapping
2025-10-27 12:31:42 -07:00
Kubernetes Prow Robot
59616d50fd Merge pull request #134691 from SergeyKanzhelev/watchdogIsGA
Lock SystemdWatchdog feature gate
2025-10-27 03:43:37 -07:00
Dario Tranchitella
65dcb4ce2c refactor(kubeadm): including dns addon version to signature
Signed-off-by: Dario Tranchitella <dario@tranchitella.eu>
2025-10-27 10:06:23 +01:00
Francesco Romani
fd5b2efa76 node: cpumanager: migrate to contextual logging
migrate the cpumanager code to contextual logging

design musings:
- golang contexts "[...] carries deadlines, cancellation signals, and
  other request-scoped values across API boundaries and between
  processes." (see: https://pkg.go.dev/context#pkg-overview).
  Thus, it generally makes sense to add contexts to most of the APIs
  and functions  as the resource management is done in the admission flow, when
  ultimately we process a request and we have time bounds;
- however, receiving a context from the outside and depending on it
  kind also conflicts with the goal of having uniform logging and "
  - attach key/value pairs that get included in all log messages
  - add names that describe which component or operation triggered a log messages"
  (see:
https://github.com/kubernetes/enhancements/tree/master/keps/sig-instrumentation/3077-contextual-logging#summary)
  Some of this conflict is due to the transitional nature of the PRs
  which we do when updating the codelet codebase. We can envision a
  final state on which the top level caller adds identifying information
  like pod UID and pod namespace/name pair; but up until all the calling
  chain is updated and wired, the results are gonna be inconsistent.
- continuing from the point above, the most realistic transition plan
  for the kubelet is outlined in
  https://github.com/kubernetes/kubernetes/issues/130069 .
  Since we do want to move in parallel and migrate on a
  subsystem-by-subsystem basis, each subsystem will be in charge to add
  the data they want to their contexts. I think this is the only
  reasonnable way forward, and the cost will be overhead and redundancy.
  We should do sweeping changes to uniform the flows once we completed
  the full transition to ensure uniformity.
- there are some well known packages which want to operate by design
  only in in-memory data structure, which arguably can't block.
  Shoehorning a context feels not great. Instead, we intentionally pass
  only the logger, which still is the core idea of contextual logging
  (see:
https://github.com/kubernetes/kubernetes/pull/125912#discussion_r1935919144)
  examples are the topology subpackage and the cpu_assignment logic
  (takeByTopology and friends)

Signed-off-by: Francesco Romani <fromani@redhat.com>
2025-10-27 08:38:58 +01:00
Abhijit Hoskeri
a35785c033 Drop loopback clients if unused
kube-controller-manager and kube-scheduler do not use the
configured loopback clients. Drop them.

Fix up scheduler test server to not depend on
the loopback client.
2025-10-26 14:47:57 -07:00
Kubernetes Prow Robot
ec5425a6ef Merge pull request #134744 from neolit123/1.35-update-system-validators-to-v1.12.0
vendor: update system-validators to v1.12.1
2025-10-24 13:07:40 -07:00
Lubomir I. Ivanov
294ff15342 kubeadm: improve the etcd version mapping
For historic reasons kubeadm kept track of a skew of 2+
etcd version in a map in the constants.go file.

This is really not required because kubeadm supports only
2 version of etcd mapped to two Kubernetes versions,
which are essentially the control plane versions.

Refactor the constants.go map to only include 2 versions.
Make sure that's reflected in a unit test.

Instead of pinning the versions as literal numbers,
start using the version we get on build time.

Adapt various unit tests and functions to allow this change
to work, since during unit tests we need actual values
and the build versions are not populated. This is achieved
by requiring the functions to accept a map[uint8]string
used for testing.
2025-10-24 20:54:22 +02:00
Kubernetes Prow Robot
60e1f61a63 Merge pull request #133511 from BenTheElder/no-md5
eliminate md5 usage, block new usage
2025-10-24 10:59:35 -07:00
Lubomir I. Ivanov
c403fd4481 kubeadm: validate the KubeletVersion for cgroups v1
By using k8s.io/system-validators v1.12.1 a KubeletVersion
can be passed to the CgroupsValidator. The library
can then decide if to throw an error or a warning.

An error is thrown if the version is >= 1.35.

During upgrade pass a KubeletVersion that is with MINOR+1
to account for the target upgrade version. That is just
an assumption that the user will upgrade the kubelet too,
but it is better to throw an error for this
common use case instead of just a warning that is seen
after the upgrade command has finished.
2025-10-24 11:14:58 +02:00
Kubernetes Prow Robot
57c243f33c Merge pull request #134450 from mayank-agrwl/controller-contextual-logs
Replace HandleCrash and HandleError calls to use context-aware alternatives
2025-10-23 00:49:02 -07:00
Kubernetes Prow Robot
0bb040288a Merge pull request #134781 from neolit123/1.35-removete-WaitForAllControlPlaneComponents-fg
kubeadm: remove the GA WaitForAllControlPlaneComponents FG
2025-10-22 18:46:39 -07:00
Kubernetes Prow Robot
eea58e01f4 Merge pull request #134743 from marquiz/devel/configz-cgroupdriver-fix
kubelet: fix kubeletconfig.cgroupDriver in configz
2025-10-22 17:38:38 -07:00