Commit graph

7273 commits

Author SHA1 Message Date
Kubernetes Prow Robot
63b36867dd
Merge pull request #138016 from pacoxu/fix-ut-pod-group
fix PodGroup protection test flake by waiting for pod watch before delete
2026-05-11 07:01:46 +05:30
Davanum Srinivas
cacb333aad
Update pkg/controller/scheduling/podgroupprotection/podgroup_protection_controller_test.go
Co-authored-by: Ania Borowiec <anias@google.com>
2026-05-10 20:38:25 -04:00
Kubernetes Prow Robot
692d9f21dd
Merge pull request #138907 from Jefftree/remove-locked-apimachinery-feature-gates
Remove locked GA feature gates (sig-api-machinery)
2026-05-09 01:57:18 +05:30
Jefftree
dfa449fabf Remove locked GA feature gate OrderedNamespaceDeletion 2026-05-08 14:15:45 -04:00
Kubernetes Prow Robot
d9fb718434
Merge pull request #138874 from michaelasp/svmPatch
Switch to regular merge patch for SVM
2026-05-08 09:21:16 +05:30
Michael Aspinwall
7847ab6b00 Switch to regular merge patch for SVM 2026-05-08 00:31:26 +00:00
Kubernetes Prow Robot
af6d86c7cc
Merge pull request #138759 from soltysh/drop_job_features
Drop job features
2026-05-07 20:09:26 +05:30
Kubernetes Prow Robot
a11a1367fb
Merge pull request #138294 from Fedosin/hpa-immediate-enqueue
hpa: eliminate reconciliation delay on HPA creation and spec changes
2026-05-07 16:35:18 +05:30
Maciej Szulik
c35fd21a6b
Drop JobPodReplacementPolicy after the feature GA-ed in 1.34
Signed-off-by: Maciej Szulik <soltysh@gmail.com>
2026-05-07 12:05:44 +02:00
Kubernetes Prow Robot
0e157a4b2c
Merge pull request #138368 from MyoungHaSong/fix-storageversionmigrator-test-goroutine-leak
Fix goroutine leak in storageversionmigrator migrationrunner test
2026-05-06 00:36:23 +05:30
Kubernetes Prow Robot
036205cc2e
Merge pull request #138711 from soltysh/drop_LogarithmicScaleDown
Drop LogarithmicScaleDown after the feature GA-ed in 1.31
2026-05-05 23:34:29 +05:30
Kubernetes Prow Robot
74f4ad5e38
Merge pull request #138698 from michaelasp/circuitBreaker
Ensure leases are not stale in node controller before marking unhealthy
2026-05-05 23:34:21 +05:30
Zhijun Liao
5d27870207
StatefulSet: Fix OnDelete strategy not updating CurrentRevision (#136833)
* Fix StatefulSet OnDelete strategy not updating CurrentRevision

Signed-off-by: Zhijun <dszhijun@gmail.com>

* Fix linter issue

Signed-off-by: Zhijun <dszhijun@gmail.com>

---------

Signed-off-by: Zhijun <dszhijun@gmail.com>
2026-05-05 21:12:24 +05:30
Maciej Szulik
57a80ebae8
Drop JobSuccessPolicy after the feature GA-ed in 1.33
Signed-off-by: Maciej Szulik <soltysh@gmail.com>
2026-05-05 11:09:40 +02:00
Maciej Szulik
432a3477cc
Drop JobBackoffLimitPerIndex after the feature GA-ed in 1.33
Signed-off-by: Maciej Szulik <soltysh@gmail.com>
2026-05-05 11:09:35 +02:00
Michael Aspinwall
9991d72c6b Add circuit breaker approach to ensure leases are not stale in node controller 2026-05-04 22:14:10 +00:00
Maciej Szulik
3a8fa19cae
Drop LogarithmicScaleDown after the feature GA-ed in 1.31
Signed-off-by: Maciej Szulik <soltysh@gmail.com>
2026-05-04 16:27:43 +02:00
Kubernetes Prow Robot
85a9fce0f9
Merge pull request #138680 from soltysh/cleanup_statefulset
Cleanup statefulset helpers and tests
2026-04-30 15:35:24 +05:30
Maciej Szulik
12c48e2158
Squash similar statefulset updates tests under a single table driven test
Signed-off-by: Maciej Szulik <soltysh@gmail.com>
2026-04-30 11:06:00 +02:00
Maciej Szulik
de7588393c
Squash similar pod delete tests under a single table driven test
Signed-off-by: Maciej Szulik <soltysh@gmail.com>
2026-04-29 11:57:38 +02:00
Maciej Szulik
724b3372df
Cleanup statefulset controller helpers
- squash isFailed and isSucceeeded under single isTerminalPhase
- remove dropParentName in favor of getParentNameAndOrdinal

Signed-off-by: Maciej Szulik <soltysh@gmail.com>
2026-04-29 11:54:28 +02:00
zak905
04286814e7 clean up: remove loop variable capture 2026-04-28 23:53:27 +02:00
Mikhail Fedosin
10742ec428 hpa: eliminate reconciliation delay on HPA creation and spec changes
Previously, creating or updating an HPA always went through
AddRateLimited, delaying reconciliation by the full resync period
(default 15s). This causes a noticeable lag between applying an HPA
and seeing it take effect, and grows worse with longer resync
intervals (e.g. 60s).

Switch enqueueHPA from queue.AddRateLimited to queue.Add so that
newly created HPAs are processed immediately. In updateHPA, compare
the Generation field (gated behind the HPAGeneration feature) to
distinguish spec changes from status-only updates: spec changes
trigger immediate reconciliation via queue.Add, while status-only
changes remain rate-limited to avoid the hot-loop from
kubernetes#42715 where the controller's own status writes would
re-trigger continuous reconciliation. When HPAGeneration is disabled,
all updates fall back to rate-limited enqueue (the original behavior).

Type-assertion fallbacks in updateHPA (e.g. DeletedFinalStateUnknown)
now also use rate-limited enqueue to prevent any theoretical hot-loop.

The periodic resync cadence is unaffected: processNextWorkItem
continues to call AddRateLimited after every reconciliation cycle.
2026-04-27 10:15:58 +02:00
Patrick Ohly
67800794aa ktesting: create client-go/ktesting
The client-go variant of ktesting is a superset of the normal
ktesting, which makes it possible to get the full original
functionality simply by changing the import path.
2026-04-24 21:54:19 +02:00
Kubernetes Prow Robot
ffa41ed792
Merge pull request #136920 from ysam12345/master
Fix empty namespace when fetching existing job in cronjob controller
2026-04-24 22:02:47 +05:30
Kubernetes Prow Robot
301f9afd23
Merge pull request #138228 from adrianmoisey/hpa-generation
Handle HPA generation fields
2026-04-24 21:04:46 +05:30
Kubernetes Prow Robot
4c7a3becca
Merge pull request #138558 from omerap12/clean-hpa-ut
HPA: Remove duplicated unit tests
2026-04-24 18:42:48 +05:30
Adrian Moisey
2c4064f31c
Handle HPA generation fields 2026-04-24 14:41:49 +02:00
Omer Aplatony
ae0a48e142 Remove duplicated ut
Signed-off-by: Omer Aplatony <omerap12@gmail.com>
2026-04-23 22:07:42 +00:00
Kubernetes Prow Robot
e0cae9a19e
Merge pull request #138451 from michaelasp/registerSTSMetric
Register Statefulset Metric for Reconcile skips
2026-04-24 02:58:45 +05:30
Kubernetes Prow Robot
b36864202b
Merge pull request #137755 from HirazawaUi/remove-SidecarContainers-feature-gate
Remove SidecarContainers feature gate
2026-04-23 08:16:45 +05:30
Kubernetes Prow Robot
1a22ad0fd2
Merge pull request #138408 from johnbelamaric/fix-dra-claim-flapping
Fix flapping pod.status.resourceClaimStatuses
2026-04-23 07:21:33 +05:30
Kubernetes Prow Robot
ad1c87b481
Merge pull request #138397 from omerap12/cleanup-hpa
HPA: Clean up duplicate unit tests
2026-04-23 07:21:19 +05:30
Kubernetes Prow Robot
74b206cc04
Merge pull request #138345 from soltysh/deployment_cleanup
Deployment controller cleanups
2026-04-23 06:08:19 +05:30
Kubernetes Prow Robot
82e8d2fe26
Merge pull request #138181 from michaelasp/dsExpectations
Update comments to explain why we delete expectations on all errors in DaemonSet
2026-04-23 06:06:52 +05:30
Kubernetes Prow Robot
ad36c93e0c
Merge pull request #138022 from michaelasp/svmResetMapper
Reset the rest mapper for recent discovery operations in SVM
2026-04-23 05:10:44 +05:30
MyoungHaSong
8e586c5071
Fix goroutine leaks in ephemeral volume controller test (#137970)
* Fix goroutine leaks in ephemeral volume controller test

Use context.WithCancel and properly shut down the informer factory
and workqueue in TestSyncHandler to prevent goroutine leaks.

Previously, the test used context.Background() which never cancels,
leaving informer and workqueue goroutines running after test completion.
Now that context support has been added to tools/cache (#126387),
the informers can be cleanly shut down via context cancellation.

Also add goleak.VerifyTestMain to detect goroutine leak regressions.

* Remove year from copyright header in main_test.go

* Drop main_test.go per review feedback
2026-04-23 04:15:52 +05:30
Kubernetes Prow Robot
f71292253d
Merge pull request #137744 from dims/dsrinivas/issue-137263-pv-controller-sync
persistentvolume: deflake TestControllerSync 5-2-3 startup race
2026-04-23 04:15:00 +05:30
Kubernetes Prow Robot
6bf148ce02
Merge pull request #137666 from soltysh/issue137409
Parallel pod management should not count old, broken pods for maxUnavailable budget
2026-04-23 04:14:45 +05:30
Jeffrey Ying
e5033d1fde
Simplify deployment controller deletePod logic, drop network call (#136639)
* Simplify deployment controller deletePod logic and avoid extra network call

* Fix tests
2026-04-23 03:20:01 +05:30
Keisuke Ishigami
4fd1a1c099
check the job owner reference in the cronjob reconcile loop (#133313)
* check the job owner reference in the cronjob reconcile loop

* use indexer to get jobs to be reconciled

* chore

* Update pkg/controller/cronjob/cronjob_controllerv2.go

Co-authored-by: Filip Křepinský <fkrepins@redhat.com>

* delete unnecessary comment

* move jobIndexer place

* Update pkg/controller/cronjob/cronjob_controllerv2.go

Co-authored-by: Maciej Szulik <soltysh@gmail.com>

* jobs -> jobsjobsToBeReconciled

* fix var name

---------

Co-authored-by: Filip Křepinský <fkrepins@redhat.com>
Co-authored-by: Maciej Szulik <soltysh@gmail.com>
2026-04-23 03:18:49 +05:30
Tzu-Chien Yu
4646ccd74f cronjob: use cronjob namespace when fetching existing job 2026-04-22 15:41:04 +00:00
Maciej Szulik
de88e7598c
Parallel pod management should accordingly count old unavailable
and terminated pods for maxUnavailable

This change ensures that Parallel pod management in statefulset controller
counts old unavailable pods as candidates for rollouts, but leaving
terminating pods untouched. All the disruptions should always ensure
that the statefulset stays within defined maxUnavilable budget.

Signed-off-by: Maciej Szulik <soltysh@gmail.com>
2026-04-20 16:30:59 +02:00
Michael Aspinwall
0d78c8191d Register statefulset metrics for skips 2026-04-17 19:04:29 +00:00
John Belamaric
57aae64982 Fix flapping pod.status.resourceClaimStatuses
resourceclaimcontroller: fix incorrect SSA apply in syncPod method

The ResourceClaimController's syncPod method only includes new
resource claims in the server-side apply, not existing claims. Since
this controller is the owning fieldManager, SSA removes the missing
existing keys. This results in flapping between claims when more than
one claim is assigned to the Pod.

This fix includes the existing claims in the SSA request.

Signed-off-by: John Belamaric <jbelamaric@google.com>
2026-04-17 14:56:18 +00:00
danny.song
09d60b3606 Use ktesting.NewTestContext instead of context.WithCancel 2026-04-16 19:39:59 +09:00
Omer Aplatony
62ce934202 removed TestScaleDownWithScalingRules (duplicate of TestScaleDown )
Signed-off-by: Omer Aplatony <omerap12@gmail.com>
2026-04-15 13:20:54 +00:00
Omer Aplatony
a6dce1229b removed unused testThis var and its unit test case
Signed-off-by: Omer Aplatony <omerap12@gmail.com>
2026-04-15 13:09:46 +00:00
Omer Aplatony
8a887a11db removed TestScaleUpHotCpuNoScaleWouldScaleDown (identical to TestScaleUpCMUnreadyandCpuHot)
Signed-off-by: Omer Aplatony <omerap12@gmail.com>
2026-04-15 13:08:14 +00:00
Omer Aplatony
f1f94dd037 removed duplicated unit test case ( same as 'scaleDown with spec MinReplicas limitation with large pod policy') 2026-04-15 12:51:58 +00:00