Commit Graph

126628 Commits

Author SHA1 Message Date
Patrick Ohly
021c9fb92f DRA CEL: add benchmark
Expression evaluation in all scenarios gets benchmarked where compilation
works. A pending optimization in another PR caches compiled expressions, so the
time for compilation will become less important. What matters is the actual
evaluation.
2024-10-23 21:24:45 +02:00
Patrick Ohly
425f694fe6 DRA CEL: log actual cost
This may be useful for validating the cost estimate.
2024-10-23 21:24:45 +02:00
Patrick Ohly
7b0071d71b DRA CEL: disable runtime cost check
In DRA, the cost check is done only at validation time.  At runtime, any
expression that passed validation gets executed without interrupting it. The
advantage is that it becomes easier to change the limit because stored
expression do not suddenly fail after an up- or downgrade. The limit could
even become a configuration parameter of the apiserver because that is the only
place where the limit gets checked
2024-10-23 21:24:45 +02:00
Patrick Ohly
39f2592863 DRA CEL: avoid redundant cel.CostTracking
It's already called by the base environment.
2024-10-23 21:24:45 +02:00
Patrick Ohly
5e514f5fcb DRA CEL: fix error checking in unit test
Not getting an expected error wasn't checked.
2024-10-23 21:24:45 +02:00
Patrick Ohly
7995b6f182 DRA CEL: add test case for runtime cost limit check
At the moment, the cost also gets checked at runtime. This test case
ensures that this check is really active.
2024-10-23 21:24:45 +02:00
Patrick Ohly
f548fc2264 DRA API: implement CEL cost limit
The main purpose is to protect against denial-of-service attacks.  Scheduling
time depends a lot on unpredictable factors and expected scheduling time also
varies, so no attempt is made to limit the overall time spent on evaluating CEL
expressions per claim.
2024-10-23 21:24:45 +02:00
Mark Sasnal
f7e9766b4d Added policy_options and policy_static unit tests 2024-10-23 15:05:46 -04:00
carlory
aa3e1fbf35 Fix volume modify e2e tests because pv controller set the current vac once the pvc is bound 2024-10-23 14:27:59 -04:00
Ed Bartosh
2ac5dfe379 e2e_node: check container metrics conditionally
When PodAndContainerStatsFromCRI FG is enabled, Kubelet tries to get
list of metrics from the CRI runtime using CRI API 'ListMetricDescriptors'.

As this API is not implemented in neither CRI-O nor Containerd versions
used in the test-infra, ResourceMetrics test case fails to gather
certain container metrics.

Excluding container metrics from the expected list of metrics if
PodAndContainerStatsFromCRI is enabled should solve the issue.
2024-10-23 21:08:36 +03:00
Aldo Culquicondor
5fab6175b7 Remove alculquicondor from job approvers
Change-Id: I2b1514ff70108602a589522cbb63dcdc88849313
2024-10-23 17:58:55 +00:00
Hemant Kumar
3c1576d47c Add e2e for fsGroupChangePolicy for RWOP volume types 2024-10-23 13:47:15 -04:00
Kubernetes Prow Robot
352056f09d
Merge pull request #127757 from torredil/scheduler-bugfix-5123
scheduler: Improve CSILimits plugin accuracy by using VolumeAttachments
2024-10-23 18:12:52 +01:00
carlory
c7e384f9ff kubelet: fix a bug where kubelet drops the QOSClass field of the Pod's status when it rejects a Pod
Co-authored-by: Sergey Kanzhelev <S.Kanzhelev@live.com>
2024-10-24 01:01:04 +08:00
Monis Khan
e4d10cfb1b
Add test to confirm default content type used by core client
Signed-off-by: Monis Khan <mok@microsoft.com>
2024-10-23 11:35:32 -04:00
Monis Khan
6595fa4026
Fix tests that assume core clients use JSON
Signed-off-by: Monis Khan <mok@microsoft.com>
2024-10-23 11:35:30 -04:00
Monis Khan
032e7f1556
Generated
Signed-off-by: Monis Khan <mok@microsoft.com>
2024-10-23 11:35:28 -04:00
Monis Khan
c2ae465355
Use protobuf for core clients
Signed-off-by: Monis Khan <mok@microsoft.com>
2024-10-23 10:56:34 -04:00
Monis Khan
fe1eda0649
client-go/rest: move content type wiring from client to request
Signed-off-by: Monis Khan <mok@microsoft.com>
2024-10-23 10:56:32 -04:00
zhifei92
80a0096ee2 fix: Add a thread-safe logBuffer for the watchdog unit test. 2024-10-23 22:30:32 +08:00
Kubernetes Prow Robot
66e3401225
Merge pull request #128264 from mimowo/promote-pod-failure-tests
Promote the Job pod failure policy to Conformance
2024-10-23 14:23:00 +01:00
Kubernetes Prow Robot
9b9831baca
Merge pull request #127926 from Nordix/esotsal/topology_manager_in_local_up_cluster
Configure topology manager policy in local-up-cluster
2024-10-23 14:22:53 +01:00
dom4ha
b3c4fe48e9 Tune PreemptionAsync and Unschedulable tests threshold and params. 2024-10-23 12:24:10 +00:00
Kubernetes Release Robot
86ec185db4 CHANGELOG: Update directory for v1.31.2 release 2024-10-23 12:18:32 +00:00
Kubernetes Prow Robot
035e272cb1
Merge pull request #127341 from mjudeikis/mjudeikis/deprecate.ch.fully
Fully deprecate StopCh
2024-10-23 12:30:52 +01:00
Sotiris Salloumis
4e0581ee21 Configure topology manager option in local-up-cluster
This commit allows the configuration of topology manager
option with the use of environment variable, following
same approach as done for configuring cpumanager policy
options.
2024-10-23 13:11:10 +02:00
Kubernetes Prow Robot
5ffb0528dd
Merge pull request #126214 from 20202200/20202200-patch-1
Fix a spelling error of hash in the description of the build script
2024-10-23 11:00:52 +01:00
Stephen Kitt
7918e9f0cb
Add a unit test for heuristicsCopyFileLogs
Signed-off-by: Stephen Kitt <skitt@redhat.com>
2024-10-23 11:58:52 +02:00
Stephen Kitt
7b730fcd73
Use ptr.To instead of a specific pointer function
Signed-off-by: Stephen Kitt <skitt@redhat.com>
2024-10-23 11:58:52 +02:00
Stephen Kitt
9f2a02a723
kubelet: validate service names with slashes
Signed-off-by: Stephen Kitt <skitt@redhat.com>
2024-10-23 11:58:52 +02:00
Stephen Kitt
dbfab994bf
kubelet: explicit variable names in Test_validateServices
Signed-off-by: Stephen Kitt <skitt@redhat.com>
2024-10-23 11:58:52 +02:00
likakuli
212c4c4851 feat: revert #103979 for it's duplicated
Signed-off-by: likakuli <1154584512@qq.com>
2024-10-23 11:18:42 +02:00
Kubernetes Prow Robot
c6669ea7d6
Merge pull request #127155 from ffromani/alignment-metrics
node: metrics: add resource alignment metrics
2024-10-23 09:54:58 +01:00
Kubernetes Prow Robot
403fcab520
Merge pull request #127036 from oscgu/chore/rm-ioutil-1
chore(cmd): rm ioutil
2024-10-23 09:54:52 +01:00
Kubernetes Prow Robot
ae53151cb4
Merge pull request #127044 from oscgu/chore/rm-ioutil-8
chore(staging/cloud-provider): rm ioutil
2024-10-23 08:30:59 +01:00
Kubernetes Prow Robot
743f5a1a02
Merge pull request #127038 from oscgu/chore/rm-ioutil-3
chore(client): rm ioutil
2024-10-23 08:30:52 +01:00
googs1025
e940b86e86 chore(scheduler): add unit test for framework preemption part 2024-10-23 15:23:11 +08:00
Kubernetes Prow Robot
2002023a4e
Merge pull request #127656 from jdtuhui/testifylint/formatter@test/utils
fix: enable formatter rule from testifylint in module test/utils
2024-10-23 07:26:52 +01:00
Francesco Romani
c025861e0c node: metrics: add resource alignment metrics
In order to improve the observability of the resource management
in kubelet, cpu allocation and NUMA alignment, we add more metrics
to report if resource alignment is in effect.

The more precise reporting would probably be using pod status,
but this would require more invasive and riskier changes,
and possibly extra interactions to the APIServer.

We start adding metrics to report if containers got their
compute resources aligned.
If metrics are growing, the assingment is working as expected;
If metrics stay consistent, perhaps at zero, no resource
alignment is done.

Extra fixes brought by this work
- retroactively add labels for existing tests
- running metrics test demands precision accounting to avoid flakes;
  ensure the node state is restored pristine between each test, to
  minimize the aforementioned risk of flakes.
- The test pod command line was wrong, with this the pod could not
  reach Running state. That gone unnoticed so far because
  no test using this utility function actually needed a pod
  in running state.

Signed-off-by: Francesco Romani <fromani@redhat.com>
2024-10-23 08:05:38 +02:00
Kubernetes Release Robot
fdc48b929d CHANGELOG: Update directory for v1.30.6 release 2024-10-23 04:40:14 +00:00
Kubernetes Release Robot
17ecef580c CHANGELOG: Update directory for v1.29.10 release 2024-10-23 04:37:31 +00:00
Kubernetes Release Robot
6d99b1c843 CHANGELOG: Update directory for v1.28.15 release 2024-10-23 04:34:59 +00:00
Jeffrey Ying
78afa9ae4b
remove unused code when build garbageCollector (#128277)
* remote unused code when build garbageCollector

Change-Id: Ib0474a8da6b250315fd400fb30b6a0a8c4e8ace4

* remove unused import

---------

Co-authored-by: 孔令飞 <colin404@foxmail.com>
2024-10-23 05:28:58 +01:00
Kubernetes Prow Robot
cdc0cf5c10
Merge pull request #128237 from kolyshkin/userns
pkg/kubelet/userns/inuserns: use moby/sys/userns
2024-10-23 05:28:51 +01:00
Kubernetes Prow Robot
ed696ecd20
Merge pull request #127753 from skitt/missing-go-env
hack: configure Go environments where necessary
2024-10-23 03:46:59 +01:00
Kubernetes Prow Robot
16dca1c330
Merge pull request #126697 from fedebongio/patch-1
Update OWNERS file in client-go/tools/leaderelection adding jefftree
2024-10-23 03:46:52 +01:00
Kubernetes Prow Robot
9c430b2f77
Merge pull request #127915 from omerap12/apiserver-util-PollUntilContextTimeout
Use PollUntilContextTimeout in flowcontrol
2024-10-23 02:21:49 +01:00
Kubernetes Prow Robot
3d7c95f241
Merge pull request #127769 from mmorel-35/golangci-lint/usestdlibvars
fix: apply usestdlibvars linter with golangci strict and hints
2024-10-23 02:21:42 +01:00
Kubernetes Prow Robot
7fff5b6b02
Merge pull request #127566 from zhifei92/integrate-watchdog
integrate kubelet with the systemd watchdog
2024-10-23 02:21:34 +01:00
Kubernetes Prow Robot
41c2e228cc
Merge pull request #127222 from chengjoey/perf/get-pod-service-memberships
perf: optimize the `GetPodServiceMemberships` function
2024-10-23 02:21:27 +01:00