Commit Graph

134908 Commits

Author SHA1 Message Date
aviralgarg05
6264b559c9 Fix flaky TestApplyCRDuringCRDFinalization test
This PR fixes the flaky TestApplyCRDuringCRDFinalization test that was failing
intermittently on slower systems (s390x architecture, race detector builds).

The root cause was a race condition where the test would attempt to apply a CR
immediately after requesting CRD deletion, without waiting for the CRD to
actually enter the terminating state. The fix explicitly waits for the CRD
to have the Terminating condition set to True before attempting the apply.
2026-01-14 00:41:39 +05:30
Lalit Chauhan
d576a57620 Fix staticcheck lint error in validation-gen
Remove unnecessary assignment to blank identifier.
2026-01-13 17:56:23 +00:00
Lalit Chauhan
7e5c081339 validation-gen: Implement declarative validation native logic 2026-01-13 17:56:22 +00:00
Lalit Chauhan
bccf92dc3f Add DV support for cross field validators 2026-01-13 17:56:22 +00:00
Kubernetes Prow Robot
c6be052768 Merge pull request #129344 from pohly/log-client-go-apimachinery-network-util
apimachinery: contextual logging in network util code
2026-01-13 23:07:39 +05:30
Patrick Ohly
c16a07a8b1 featuregate: contextual logging
This is primarily useful in unit tests and therefore supported by
featuregate/testing. Without this, all warnings are emitted to stderr, with no
connection to the test which caused the warning to be emitted.

When a single test fails, `go test` started by showing all warnings triggered by
any test, not just the failed test:

    I1121 18:50:28.112284  396950 feature_gate.go:466] feature gates: {map[DRADeviceTaintRules:true DRADeviceTaints:true]}
    ...
    I1121 18:50:29.704907  396950 feature_gate.go:466] feature gates: {map[DRADeviceTaintRules:false DRADeviceTaints:false]}
    --- FAIL: TestAll (1.58s)
        --- FAIL: TestAll/Eviction (0.02s)

This warning was actually slightly broken: it passed an atomic.Value to Infof,
not the map. This violates the "must not be copied after first use" rule
for atomic.Value (thus wasn't thread-safe) and printed the value in an awkward
way (extra {}).

Now it shows that the feature gates are modified inside TestAll (in this example):

    --- FAIL: TestAll (1.56s)
        feature_gate.go:170: I1124 17:31:27.245108] Updated featureGates={"DRADeviceTaintRules":true,"DRADeviceTaints":true}
        --- FAIL: TestAll/Eviction (0.02s)
            --- FAIL: TestAll/Eviction/initial (0.00s)
        ...

        feature_gate.go:170: I1124 17:31:28.821975] Updated featureGates={"DRADeviceTaintRules":false,"DRADeviceTaints":false}
    FAIL
    FAIL	k8s.io/kubernetes/pkg/controller/devicetainteviction	1.602s
2026-01-13 18:20:59 +01:00
Kubernetes Prow Robot
c20e0bc541 Merge pull request #135958 from serathius/watchcache-store
Move store to cacher subpackage.
2026-01-13 21:41:40 +05:30
Patrick Ohly
588bba42c7 apimachinery: contextual logging in network util code 2026-01-13 16:55:36 +01:00
Kubernetes Prow Robot
58000ddd0e Merge pull request #136195 from HirazawaUi/upgrade-containerd-version
Upgrade the COS version (upgrade containerd to version v2.1+)
2026-01-13 19:39:38 +05:30
Sascha Grunert
1abe2c4860 Fix credential test by setting AlwaysVerify policy
The test expects unauthorized pods to be blocked from accessing cached
private images, but the default policy (NeverVerifyPreloadedImages)
allows access to any image previously pulled by the kubelet.

Configure the kubelet to use AlwaysVerify policy for this test, which
enforces credential checks for all images regardless of pull history.

Signed-off-by: Sascha Grunert <sgrunert@redhat.com>
2026-01-13 13:52:43 +01:00
Marek Siarkowicz
eb35b0a657 Add serathius as approver for apiserver storage 2026-01-13 13:22:05 +01:00
HirazawaUi
3164b73d28 upgrade containerd version to v2.1+ 2026-01-13 18:13:52 +08:00
Kubernetes Prow Robot
9f6977db54 Merge pull request #136086 from richabanker/graduate-watch_list_duration_seconds-BETA
Graduate watch_list_duration_seconds to BETA
2026-01-13 15:29:37 +05:30
Marin Atanasov Nikolov
73a0b5f08d code-generator/defaulter-gen: remove a leftover 2026-01-13 11:12:07 +02:00
Kubernetes Prow Robot
6b541e0b58 Merge pull request #135977 from pohly/test-parallel-fix
make test: fix support for PARALLEL
2026-01-13 09:51:41 +05:30
Kubernetes Prow Robot
e0464327ce Merge pull request #135770 from dnaeon/code-generator/defaulter-gen
code-generator/defaulter-gen: generate defaults only if required tags are present
2026-01-13 08:33:36 +05:30
Kubernetes Prow Robot
fa8340b207 Merge pull request #136117 from lalitc375/dv-strategy
Add utilities to allow strategy.go files to enable DV native validations
2026-01-13 07:43:43 +05:30
Kubernetes Prow Robot
d68d48073f Merge pull request #136112 from danwinship/network-1.36-cleanup
Drop TopologyAwareHints and ServiceTraficDistribution feature gates
2026-01-13 07:43:36 +05:30
Kubernetes Prow Robot
31cdb5de61 Merge pull request #136183 from aramase/aramase/i/fix_kms_test_136181
test: fix kind local registry config for kms ci jobs
2026-01-13 05:25:38 +05:30
helayoty
6a9f3a1509 Remove descriminated union
Signed-off-by: helayoty <heelayot@microsoft.com>
2026-01-12 14:22:58 -08:00
helayoty
f17edf7efb Restructure validation tests to check declarative coverage 2026-01-12 14:22:58 -08:00
helayoty
251832a33c Add union validation tags 2026-01-12 14:22:58 -08:00
helayoty
b75e665a7d Add +k8s:minimum validation tag 2026-01-12 14:22:57 -08:00
helayoty
ac8fe6b94e Add +k8s:format validation tags 2026-01-12 14:22:57 -08:00
helayoty
ac7b776537 Add +k8s:listType, +k8s:listMapKey, and +k8s:maxItems validation tags 2026-01-12 14:22:57 -08:00
helayoty
36ddf6c471 Add +k8s:required and +k8s:optional validation tags 2026-01-12 14:22:57 -08:00
helayoty
ce9797aa47 Add k8s-path-segment-name format validator 2026-01-12 14:22:57 -08:00
helayoty
f4c839950e Wire up declarative validation for Workload API 2026-01-12 14:22:55 -08:00
Lalit Chauhan
42b8ceee21 Address feedbacks 2026-01-12 22:09:50 +00:00
Kubernetes Prow Robot
1c894014eb Merge pull request #136161 from dims/update-golang-x-deps-jan2026
Update golang.org/x dependencies to latest versions
2026-01-13 03:05:37 +05:30
Anish Ramasekar
900a8030f3 test: fix kind local registry config for kms ci jobs
Signed-off-by: Anish Ramasekar <anish.ramasekar@gmail.com>
2026-01-12 12:59:14 -08:00
Kubernetes Prow Robot
477b99a8d8 Merge pull request #135759 from Abhigyan-Shekhar/fix-cel-race-condition
FIX: Deep copy MapType in CEL composition to prevent data race
2026-01-13 02:15:08 +05:30
Kubernetes Prow Robot
f2143d70db Merge pull request #135597 from alvaroaleman/plumb-context
Service account controller: Wire through context
2026-01-13 02:15:00 +05:30
Kevin Hannon
986020d6bd sync check in batch stategy to match AllowMutableSchedulingDirectives and AllowMutablePodResources 2026-01-12 15:40:34 -05:00
Omer Aplatony
6cbb58349d HPA: Enable DV support for MaxReplicas (#135412)
Signed-off-by: Omer Aplatony <omerap12@gmail.com>
2026-01-13 00:54:09 +05:30
Kubernetes Prow Robot
19d344fbee Merge pull request #135887 from ErikJiang/fix/log-validation-messages
fix log validation messages
2026-01-13 00:00:17 +05:30
Kubernetes Prow Robot
f366ba158a Merge pull request #135668 from yliaog/implicit
added unit test case to ensure implicit DRA extended resource is handled properly during pod admission at kubelet
2026-01-13 00:00:09 +05:30
Kubernetes Prow Robot
4a29c352ce Merge pull request #135949 from lalitc375/stability-tag-promotion
Promote validation-gen tags to Stable
2026-01-12 22:24:29 +05:30
Kubernetes Prow Robot
210881f0f0 Merge pull request #135485 from saschagrunert/fix-device-plugin-termination-grace-period
Fix device plugin admission failure after container restart
2026-01-12 22:24:22 +05:30
Kubernetes Prow Robot
af6c58193c Merge pull request #135369 from saschagrunert/serial-tests
test: Fix image credential pulls test node scheduling
2026-01-12 22:24:13 +05:30
Kubernetes Prow Robot
b9e2575a54 Merge pull request #135992 from bart0sh/PR212-migrate-remaining-kubelet-subdirs-to-contextual-logging
Migrate remaining kubelet subdirs to contextual logging
2026-01-12 19:58:41 +05:30
Kubernetes Prow Robot
b89a81cfcb Merge pull request #136167 from Karthik-K-N/update-funcs
DRA: remove deprecated test method usage, fix linter hints
2026-01-12 18:04:39 +05:30
Sascha Grunert
172a65c71d Fix device plugin admission failure after container restart
When a container restarts before kubelet restarts, containerMap has
multiple entries (old exited + new running). GetContainerID() may
return the exited container, causing the running check to fail. Fixed
by checking if ANY container for the pod/name is running.

Also filter terminal pods from podresources since they no longer
consume resources, and fix test error handling to avoid exiting
Eventually immediately on transient errors.

Signed-off-by: Sascha Grunert <sgrunert@redhat.com>
2026-01-12 11:55:25 +01:00
Kubernetes Prow Robot
6df7e09ad9 Merge pull request #135911 from ShaanveerS/add-udp-agnhost
Add UDP and explicit TCP support to agnhost porter
2026-01-12 16:16:06 +05:30
Karthik Bhat
8962f08815 Remove deprecated test methods 2026-01-12 16:15:04 +05:30
Ed Bartosh
b0375e76f0 Add pohly and bart0sh as approvers for kubelet/cm/dra 2026-01-12 12:43:07 +02:00
Ed Bartosh
0dc83930de logcheck: move all kubelet subdirs to contextual logging 2026-01-12 12:36:59 +02:00
Ed Bartosh
1c48267565 migrate pkg/kubelet/events to contextual logging 2026-01-12 12:36:59 +02:00
Ed Bartosh
597c20d050 migrate kubelet/stats to contextual logging 2026-01-12 12:36:59 +02:00
Ed Bartosh
1fa4951dd5 migrate kubelet/podcertificate to contextual logging 2026-01-12 12:36:58 +02:00