Andy Goldstein
26e3dab78b
garbagecollector: use contextual logging
...
Signed-off-by: Andy Goldstein <andy.goldstein@redhat.com >
2023-03-08 08:37:56 -05:00
Kubernetes Prow Robot
1e84987bac
Merge pull request #115799 from pohly/test-util-data-race
...
test/utils: avoid data race during parallel create
2023-02-16 01:53:38 -08:00
Patrick Ohly
501a7678b3
test/utils: avoid data race during parallel create
...
The client-go Create call writes into the object that it gets passed. Each call
therefore needs its own copy when invoked in parallel.
Seen in
go test -v -timeout=0 -bench=.*/SchedulingBasic/5000Nodes -race ./test/integration/scheduler_perf
WARNING: DATA RACE
Read at 0x00c003fa5b00 by goroutine 45227:
k8s.io/apimachinery/pkg/apis/meta/v1.(*TypeMeta).GroupVersionKind()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/meta.go:126 +0x84
k8s.io/apimachinery/pkg/runtime.WithVersionEncoder.Encode()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/runtime/helper.go:231 +0x176
k8s.io/apimachinery/pkg/runtime.(*WithVersionEncoder).Encode()
<autogenerated>:1 +0xfb
k8s.io/apimachinery/pkg/runtime.Encode()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/runtime/codec.go:50 +0xb3
k8s.io/client-go/rest.(*Request).Body()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/client-go/rest/request.go:469 +0x884
k8s.io/client-go/kubernetes/typed/core/v1.(*pods).Create()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/client-go/kubernetes/typed/core/v1/pod.go:126 +0x264
k8s.io/kubernetes/test/utils.CreatePodWithRetries.func1()
/nvme/gopath/src/k8s.io/kubernetes/test/utils/create_resources.go:61 +0x111
k8s.io/apimachinery/pkg/util/wait.ConditionFunc.WithContext.func1()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/util/wait/wait.go:222 +0x30
k8s.io/apimachinery/pkg/util/wait.runConditionWithCrashProtectionWithContext()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/util/wait/wait.go:262 +0x7b
k8s.io/apimachinery/pkg/util/wait.runConditionWithCrashProtection()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/util/wait/wait.go:255 +0x5c
k8s.io/apimachinery/pkg/util/wait.ExponentialBackoff()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/util/wait/wait.go:431 +0x67
k8s.io/kubernetes/test/utils.RetryWithExponentialBackOff()
/nvme/gopath/src/k8s.io/kubernetes/test/utils/create_resources.go:53 +0x1be
k8s.io/kubernetes/test/utils.CreatePodWithRetries()
/nvme/gopath/src/k8s.io/kubernetes/test/utils/create_resources.go:70 +0x1bf
k8s.io/kubernetes/test/utils.makeCreatePod()
/nvme/gopath/src/k8s.io/kubernetes/test/utils/runners.go:1339 +0x68
k8s.io/kubernetes/test/utils.CreatePod.func1()
/nvme/gopath/src/k8s.io/kubernetes/test/utils/runners.go:1349 +0xab
k8s.io/client-go/util/workqueue.ParallelizeUntil.func1()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/client-go/util/workqueue/parallelizer.go:90 +0x1c1
Previous write at 0x00c003fa5b00 by goroutine 45250:
k8s.io/apimachinery/pkg/apis/meta/v1.(*TypeMeta).SetGroupVersionKind()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/meta.go:121 +0x1cc
k8s.io/apimachinery/pkg/runtime.WithVersionEncoder.Encode()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/runtime/helper.go:241 +0x408
k8s.io/apimachinery/pkg/runtime.(*WithVersionEncoder).Encode()
<autogenerated>:1 +0xfb
k8s.io/apimachinery/pkg/runtime.Encode()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/runtime/codec.go:50 +0xb3
k8s.io/client-go/rest.(*Request).Body()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/client-go/rest/request.go:469 +0x884
k8s.io/client-go/kubernetes/typed/core/v1.(*pods).Create()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/client-go/kubernetes/typed/core/v1/pod.go:126 +0x264
k8s.io/kubernetes/test/utils.CreatePodWithRetries.func1()
/nvme/gopath/src/k8s.io/kubernetes/test/utils/create_resources.go:61 +0x111
k8s.io/apimachinery/pkg/util/wait.ConditionFunc.WithContext.func1()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/util/wait/wait.go:222 +0x30
k8s.io/apimachinery/pkg/util/wait.runConditionWithCrashProtectionWithContext()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/util/wait/wait.go:262 +0x7b
k8s.io/apimachinery/pkg/util/wait.runConditionWithCrashProtection()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/util/wait/wait.go:255 +0x5c
k8s.io/apimachinery/pkg/util/wait.ExponentialBackoff()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/util/wait/wait.go:431 +0x67
k8s.io/kubernetes/test/utils.RetryWithExponentialBackOff()
/nvme/gopath/src/k8s.io/kubernetes/test/utils/create_resources.go:53 +0x1be
k8s.io/kubernetes/test/utils.CreatePodWithRetries()
/nvme/gopath/src/k8s.io/kubernetes/test/utils/create_resources.go:70 +0x1bf
k8s.io/kubernetes/test/utils.makeCreatePod()
/nvme/gopath/src/k8s.io/kubernetes/test/utils/runners.go:1339 +0x68
k8s.io/kubernetes/test/utils.CreatePod.func1()
/nvme/gopath/src/k8s.io/kubernetes/test/utils/runners.go:1349 +0xab
k8s.io/client-go/util/workqueue.ParallelizeUntil.func1()
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/client-go/util/workqueue/parallelizer.go:90 +0x1c1
2023-02-16 08:44:42 +01:00
Kubernetes Prow Robot
908803081f
Merge pull request #115811 from danwinship/e2e-userspace-cleanup
...
Remove checks for userspace proxy mode in e2e tests
2023-02-15 18:03:49 -08:00
Kubernetes Prow Robot
292450717c
Merge pull request #115394 from ritazh/kmsv2-metrics
...
kmsv2: add metrics
2023-02-15 18:03:37 -08:00
Kubernetes Prow Robot
a25834cb5a
Merge pull request #115802 from logicalhan/webhook-metrics
...
webhook metrics top out at 2.5s but default timeout is 10s
2023-02-15 15:29:11 -08:00
Rita Zhang
bd0f7f8ee8
kmsv2: add metrics
...
Signed-off-by: Rita Zhang <rita.z.zhang@gmail.com >
2023-02-15 15:08:24 -08:00
Dan Winship
9283429f22
Remove checks for userspace proxy mode in e2e tests
...
It's gone
2023-02-15 16:30:58 -05:00
Han Kang
7b823002f3
add 25s bucket
2023-02-15 10:31:12 -08:00
Kubernetes Prow Robot
fa3d5730a4
Merge pull request #115797 from pohly/dra-test-driver-resource-limit-fix
...
e2e dra: fix resource limits in a mixed cluster
2023-02-15 09:58:33 -08:00
Han Kang
20b5205dad
use 10 seconds as the biggest bucket for webhook metrics otherwise charts will top out at 2.5s for webhook latencies
2023-02-15 09:17:41 -08:00
Kubernetes Prow Robot
e18fa74551
Merge pull request #115590 from swatisehgal/topology-mgr-duration-metrics
...
node: topology-mgr: Add metric to measure topology manager admission latency
2023-02-15 07:12:25 -08:00
Patrick Ohly
20d7fa2771
e2e dra: fix resource limits in a mixed cluster
...
The check for "resources available on a node" must treat nodes that are not
listed as "no resources available". The previous logic only worked because all
nodes were listed during E2E testing. The upcoming integration testing is
covering additional scenarios and triggered this broken case.
2023-02-15 15:12:19 +01:00
Swati Sehgal
cf21dcef51
node: topology-mgr: e2e: changes to validate admission latency metrics
...
The component was previously incorrect. This patch updates to
the correct component name.
Signed-off-by: Swati Sehgal <swsehgal@redhat.com >
2023-02-15 13:59:56 +00:00
Kubernetes Prow Robot
390ddafe9e
Merge pull request #114494 from chrishenzie/readwriteoncepod-beta
...
Graduate ReadWriteOncePod to beta, updated e2e test
2023-02-14 16:35:42 -08:00
Kubernetes Prow Robot
731238fb41
Merge pull request #115739 from ii/update-ineligible-yaml-debug-endpoints
...
Update ineligible endpoints yaml to include debug endpoints
2023-02-14 12:46:02 -08:00
Chris Henzie
f855c90c1e
chore: Update hostpath driver to v1.11.0
...
This version enforces the new SINGLE_NODE_SINGLE_WRITER CSI access mode
in NodePublishVolume.
See for more details:
https://github.com/kubernetes-csi/csi-driver-host-path/pull/381
2023-02-14 10:09:58 -08:00
Chris Henzie
0e47d90dd1
test: e2e test for ReadWriteOncePod preemption
2023-02-14 10:09:57 -08:00
Kubernetes Prow Robot
4cf352c4bb
Merge pull request #115456 from pohly/goroutine-leak-check
...
test/integration: goroutine leak check
2023-02-14 08:31:31 -08:00
Andy Goldstein
71ec5ed81d
resourcequota: use contexual logging ( #113315 )
...
Signed-off-by: Andy Goldstein <andy.goldstein@redhat.com >
2023-02-14 07:19:31 -08:00
Patrick Ohly
f131cabfa0
test: use go-uber/goleak for strict leak checking
...
It provides more readable output and has additional APIs for using it inside a
unit test. goleak.IgnoreCurrent is needed to filter out the goroutine that gets
started when importing go.opencensus.io/stats/view.
In order to handle background goroutines that get created on demand and cannot
be stopped (like the one for LogzHealth), a helper function ensures that those
are running before calling goleak.IgnoreCurrent. Keeping those goroutines
running is not a problem and thus not worth the effort of adding new APIs to
stop them.
Other goroutines are genuine leaks for which no fix is available. Those get
suppressed via IgnoreTopFunction, which works as long as that function
is unique enough.
Example output for the leak fixed in https://github.com/kubernetes/kubernetes/pull/115423 :
E0202 09:30:51.641841 74789 etcd.go:205] "EtcdMain goroutine check" err=<
found unexpected goroutines:
[Goroutine 4889 in state chan receive, with k8s.io/apimachinery/pkg/watch.(*Broadcaster).loop on top of the stack:
goroutine 4889 [chan receive]:
k8s.io/apimachinery/pkg/watch.(*Broadcaster).loop(0xc0076183c0)
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/watch/mux.go:268 +0x65
created by k8s.io/apimachinery/pkg/watch.NewBroadcaster
/nvme/gopath/src/k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/watch/mux.go:77 +0x116
>
2023-02-14 12:11:37 +01:00
Kubernetes Prow Robot
8b2545efa3
Merge pull request #115730 from ravisantoshgudimetla/remove-cgo
...
Remove cgo dependency
2023-02-13 12:49:38 -08:00
Stephen Heywood
4d2611cf58
Update ineligible endpoints yaml
...
Adding the following endpoints
- connectCoreV1GetNamespacedPodPortforward
- connectCoreV1GetNamespacedPodAttach
- connectCoreV1PostNamespacedPodAttach
2023-02-14 09:00:44 +13:00
Kubernetes Prow Robot
b8b18ecd85
Merge pull request #114051 from chrishenzie/rwop-preemption
...
[scheduler] Support preemption of pods using ReadWriteOncePod PVCs
2023-02-13 11:45:30 -08:00
ravisantoshgudimetla
d65262d1f9
Remove cgo dependency
2023-02-13 11:16:39 -05:00
Kubernetes Prow Robot
bf79066749
Merge pull request #115714 from aramase/aramase/f/kubernetes#115595
...
[KMSv2] Add kind cluster and encryption config for e2e
2023-02-13 05:43:42 -08:00
Kubernetes Prow Robot
4933005b38
Merge pull request #115697 from aojea/lbds
...
don't run loadbalancer tests on large environments
2023-02-13 05:43:30 -08:00
Kubernetes Prow Robot
8ee0d3b6e8
Merge pull request #115584 from pbeschetnov/master
...
[HPA e2e] Calculate more precise consumed CPU usage for N replicas
2023-02-13 03:27:29 -08:00
Anish Ramasekar
4e6d5dddfb
[KMSv2] Add kind cluster and encryption config for e2e
...
Signed-off-by: Anish Ramasekar <anish.ramasekar@gmail.com >
2023-02-13 06:42:54 +00:00
Antonio Ojea
244d7449ce
don't run loadbalancer tests on large environments
...
Change-Id: Id987e9469e563c0837c6437a44a65889cec2e202
2023-02-11 10:28:25 +00:00
Kubernetes Prow Robot
0424a530a4
Merge pull request #115678 from pohly/e2e-full-reports
...
e2e: revise complete report creation
2023-02-10 15:07:29 -08:00
Kubernetes Prow Robot
1749bb2991
Merge pull request #115579 from ardaguclu/fix-wait-sh-timeout
...
flaky test wait.sh: Add deployment assertion before running wait
2023-02-10 13:59:29 -08:00
Patrick Ohly
3e2b26ce52
e2e: revise complete report creation
...
The previous approach was based on the observation that some Prow jobs use the
--report-dir parameter instead of the E2E_REPORT_DIR env variable. Parsing the
command line was necessary to use the --json-report and --junit-report
parameters.
But that is complex and can be avoided by triggering the creation of complete
reports in the E2E test suite. The paths are hard-coded and relative to the
report directory to keep the code simple.
There was a report that k8s-triage started processing more data after
6db4b741dd
was merged. It's unclear whether
that was because of the new <report-dir>/ginkgo_report.xml file. To avoid
this potential problem, the reports are now in a "ginkgo" sub-directory.
While at it, error checking gets enhanced:
- Create directories at the start of
the suite and bail out early if that fails.
- *All* e2e suites using the framework do this, not just test/e2e.
- Added missing error checking of truncated JUnit report writing.
2023-02-10 10:20:20 +01:00
Arda Güçlü
e0fedec69d
(kubectl debug): Support debugging via files
...
Currently `kubectl debug` only supports passing names in command line.
However, users might want to pass resources in files by passing `-f` flag like
in all other kubectl commands.
This PR adds this ability.
2023-02-10 10:21:30 +03:00
Kubernetes Prow Robot
b2f8c8f00d
Merge pull request #115635 from bobbypage/npd-time-fix
...
test: Simplify NPD start timestamp calculation
2023-02-09 18:37:31 -08:00
Kubernetes Prow Robot
0698d9eb82
Merge pull request #115649 from aramase/grpc-metrics
...
[KMSv2] Add metrics for grpc service
2023-02-09 15:50:45 -08:00
Kubernetes Prow Robot
6e2e61bb3c
Merge pull request #115657 from saschagrunert/inject-base64
...
Allow SSH e2e node base64 key injection
2023-02-09 14:45:06 -08:00
Kubernetes Prow Robot
95c65ca3a0
Merge pull request #115454 from dgrisonnet/promote-pod-resource-metrics
...
Promote pod resource metrics to stable
2023-02-09 12:36:16 -08:00
Damien Grisonnet
49da8a1d4a
scheduler: promote pod resource metrics to stable
...
Signed-off-by: Damien Grisonnet <dgrisonn@redhat.com >
2023-02-09 20:30:45 +01:00
Anish Ramasekar
de3b2d525b
[KMSv2] Add metrics for grpc service
...
Signed-off-by: Anish Ramasekar <anish.ramasekar@gmail.com >
2023-02-09 18:51:37 +00:00
Sascha Grunert
85106dc327
Allow SSH e2e node base64 key injection
...
With the change of the CRI-O jobs to use butane, we now have a
verification for base64 data urls in place. This means that the
following URL is invalid:
```
data:text/plain;base64,GCE_SSH_PUBLIC_KEY_FILE_CONTENT
```
This means we have to pass valid base64 to the URL. To fix that, we now
allow to inject SSH key values with both, the
`GCE_SSH_PUBLIC_KEY_FILE_CONTENT` field and its base64 encoded variant.
Signed-off-by: Sascha Grunert <sgrunert@redhat.com >
2023-02-09 16:17:11 +01:00
vaibhav2107
6ab8a8fbec
Updated the change in registry
2023-02-09 09:37:44 +05:30
David Porter
7fe371a974
test: Simplify NPD start timestamp calculation
...
The NPD test checks when NPD started to determine if it is needed to
check the kubelet start event. The current logic requires parsing the
journalctl logs which is quite fragile and is broken now because of
systemd changing the expected log format.
Newer versions of systemd do not print "end at" or "logs begin at" and
instead may print "No entries", which will result in the test panicking.
```
$ journalctl -u foo.service
-- No entries --
```
For units started, it will not print "end at" or "logs begin at":
```
root@ubuntu-jammy:~# journalctl -u foo.service
Feb 08 22:02:19 ubuntu-jammy systemd[1]: Started /usr/bin/sleep 1s.
Feb 08 22:02:20 ubuntu-jammy systemd[1]: foo.service: Deactivated successfully.
```
To avoid relying on log parsing which is fragile, let's instead directly
ask systemd when the NPD service started and parse the resulting
timestamp.
Signed-off-by: David Porter <david@porter.me >
2023-02-08 13:58:45 -08:00
Kubernetes Prow Robot
468ce59183
Merge pull request #115557 from MikeSpreitzer/cleanup-path-hack
...
Simplify construction of /metrics request
2023-02-08 09:28:58 -08:00
Matthew Cary
69808b74ec
Remove obsolete GKE local SSD test
...
Change-Id: I156bd03ac740c2ebe394081d3106851f7182269f
2023-02-07 17:33:32 -08:00
Riaan Kleinhans
999e9f14f7
remove conformance tested endpoints
2023-02-08 11:55:44 +13:00
Kubernetes Prow Robot
090025f5e6
Merge pull request #115548 from pohly/e2e-wait-for-pods-with-gomega
...
e2e: wait for pods with gomega, II
2023-02-07 07:01:21 -08:00
Kubernetes Prow Robot
22b88dea36
Merge pull request #115315 from enj/enj/i/kas_kubelet_conn_close
...
kubelet/client: collapse transport wiring onto standard approach
2023-02-07 07:01:14 -08:00
Kubernetes Prow Robot
4f321041bd
Merge pull request #115537 from MadhavJivrajani/bump-tools-deps-go120
...
*: Bump golangci-lint version and adapt to new linters
2023-02-07 05:53:12 -08:00
Pavel Beschetnov
456de495ef
Calculate more precise usage for replicas
2023-02-07 12:41:36 +00:00