Commit Graph

155 Commits

Author SHA1 Message Date
Manuel Rüger fd2a1f83f3 chore: Build with go 1.22 2024-04-05 00:20:04 +02:00
Ovidiu Tirla b72faf3af9 chore: use string verb to format logging messages in tests
The %w makes the CI to fail, replacing it back to %s
2024-04-04 18:41:47 +00:00
Ovidiu Tirla 071c523e20
chore: update log message
Co-authored-by: Pranshu Srivastava <prasriva@redhat.com>
2024-04-04 19:25:02 +02:00
Ovidiu Tirla 1669ae6c77 test: lookup recursively for docs in e2e test 2024-04-03 12:32:14 +00:00
Manuel Rüger 0cb296564b chore: Bump to kubernetes 1.29 2024-03-18 16:12:17 +01:00
Manuel Rüger 5ab665a68b chore: Improve benchmark output 2023-12-13 19:02:24 +01:00
Kubernetes Prow Robot a7cb7f736a
Merge pull request #2184 from opeco17/feat/introduce-markdown-formatter
feat: introduce Markdown linter and formatter
2023-09-11 07:30:12 -07:00
opeco17 81e825dfea feat: introduce Markdown formatter 2023-09-11 22:41:43 +09:00
Manuel Rüger 08a183414b chore: Bump to kubernetes 1.28 2023-08-31 20:21:32 +02:00
opeco17 7bf825d989 feat: hot reload kubeconfig 2023-08-29 01:19:45 +00:00
Manuel Rüger 2181414c8d build: Bump dependencies 2023-08-25 12:26:29 +02:00
Manuel Rüger 17b3343d46 chore: Bump to kubernetes 1.27.x 2023-05-31 14:17:20 +02:00
Manuel Rüger b0fe5f9a1d chore: Bump dependencies for next release 2023-05-22 15:55:43 +02:00
Pranshu Srivastava 25a1d8da05
Add support for variable VKs in CRS config
Add support for variable VKs in CRS config, while maintaining a cache
of discovered GVKs in the cluster, and updating it every 30s.

Signed-off-by: Pranshu Srivastava <rexagod@gmail.com>
2023-05-20 01:26:02 +05:30
Apoorva Kulkarni 723b0faefa
add redirect to the curl command 2023-05-11 05:58:40 -07:00
Apoorva Kulkarni 205e19eed4
Use dl.k8s.io instead of hardcoded GCS URIs 2023-05-10 16:16:23 -07:00
Catherine Fang 5fae5968ac daemonset-sharding-example 2023-03-21 20:37:36 -04:00
Manuel Rüger cef8c1fa4c feat!: Remove VerticalPodAutoscaler
BREAKING CHANGE: VPA is now supported only via Custom Resource Metrics

Signed-off-by: Manuel Rüger <manuel@rueg.eu>
2023-03-16 14:37:44 +01:00
Manuel Rüger 06268ab5ef Reload CustomResourceState Config File on Change
This change adds hot reloading support for the customresourcestate
config file.

It also resolves a bug in which the customresourcestate config file was
included in the ksm config file, in which it did not get detected.

It also resolves a bug in which customresourcestatemetrics were not
added when set resources were non-default resources.

Fixes: https://github.com/kubernetes/kube-state-metrics/issues/1892
2023-01-09 17:32:09 +01:00
Manuel Rüger 89403d239a go.mod: Bump to kubernetes 1.26.0 2022-12-12 23:50:14 +01:00
Kubernetes Prow Robot 4e30f4e319
Merge pull request #1921 from dgrisonnet/simplify-metricswriter
Remove duplicated MetricsWriter implementation
2022-12-06 23:32:38 -08:00
Damien Grisonnet fa89bc91ab pkg/metrics_store: add error handling to WriteAll
Signed-off-by: Damien Grisonnet <dgrisonn@redhat.com>
2022-12-06 21:02:21 +01:00
Damien Grisonnet e355c48da1 Remove duplicated MetricsWriter implementation
Simplify the implementation of the MetricsWriter to avoid code
duplication between single and multi stores scenarios.

Signed-off-by: Damien Grisonnet <dgrisonn@redhat.com>
2022-12-06 21:02:19 +01:00
Manuel Rüger b4b8c23b97 Add Metrics for EndpointSlices
Implements https://pkg.go.dev/k8s.io/api/discovery/v1#EndpointSlice

This resourcetype is disabled by default as they are very verbose and
have a high cardinality.
Metrics from endpointslices can be used to identify if specific pods are
part of an endpoint and thus discoverable through a service.

Signed-off-by: Manuel Rüger <manuel@rueg.eu>
2022-11-26 01:44:29 +01:00
Kaito Ii 278426995e add ingress classs as nondefault resource 2022-11-24 00:07:56 +09:00
Kaito Ii 4abefe268a add ingress class metrics 2022-11-23 23:16:36 +09:00
Pranshu Srivastava f8360a8903
Add end-to-end testing to verify hot-reloading
Add end-to-end testing to verify hot-reloading for event-based changes
stemming from the config file. Also,
* sent in a doc fix that was missed
earlier:
https://github.com/kubernetes/kube-state-metrics/pull/1890/files#diff-380eca5a922c0ddbf67f04daefc6823e7ef0e197434d3a826d39c7063cdfa6d6R15,
* updated fsnotify and viper dependencies (v1.6.0 and v1.14.0
  respectively).

Signed-off-by: Pranshu Srivastava <rexagod@gmail.com>
2022-11-16 20:26:22 +05:30
Manuel Rüger 3d8abf894b e2e: Test against k8s 1.25.0
Signed-off-by: Manuel Rüger <manuel@rueg.eu>
2022-11-02 11:26:42 +01:00
Manuel Rüger 6b7027ff41 Harden and add gosec linter
Remediate:
G104: Errors unhandled.
G109: Potential Integer overflow made by strconv.Atoi result conversion to int16/32
G112: Potential Slowloris Attack because ReadHeaderTimeout is not configured in the http.Server
G304: Potential file inclusion via variable
G601: Implicit memory aliasing in for loop.

Signed-off-by: Manuel Rüger <manuel@rueg.eu>
2022-10-20 20:44:46 +02:00
Manuel Rüger 93e79fc9d8 Remove RBAC resources from default exposed metric set
These resources might create a lot of metrics,
so we won't enable them by default for now.

Signed-off-by: Manuel Rüger <manuel@rueg.eu>
2022-08-23 18:44:55 +02:00
Kubernetes Prow Robot 3532203e8f
Merge pull request #1799 from kaitoii11/rolebinding
Add support for rolebindings
2022-08-18 12:22:12 -07:00
Manuel Rüger 2f20203c09 Replace pkg/errors with stdlib errors
github.com/pkg/errors is archived and not maintained anymore.
Replace it with stdlib functions.

Signed-off-by: Manuel Rüger <manuel@rueg.eu>
2022-08-15 20:25:09 +02:00
Kaito Ii 2cd6aaa8aa fix filename and sort order 2022-08-09 23:17:20 +09:00
Kaito Ii 51df8fe763 add rolebinding metrics 2022-08-07 01:32:57 +09:00
Kaito Ii 3c9908d0b3 add role and cluster role
Signed-off-by: Kaito Ii <kaitoii1111@gmail.com>
2022-06-30 20:55:25 +09:00
Julian van den Berkmortel 6a24f639f8
Add support for the ServiceAccount resource (Ref: #1717) 2022-06-29 23:58:01 +02:00
Manuel Rüger de1902391c Switch registry from k8s.gcr.io to registry.k8s.io
Signed-off-by: Manuel Rüger <manuel@rueg.eu>
2022-06-07 13:48:26 +02:00
Manuel Rüger 42cd98e44a Bump to go 1.18.2, k8s 1.24, kind 0.14.0, prometheus 2.35.0
and several other go deps

Signed-off-by: Manuel Rüger <manuel@rueg.eu>
2022-05-26 20:09:21 +02:00
Manuel Rüger b4b0ba12d0 tests/e2e.sh: Bump to kind v0.12.0 2022-03-14 11:45:51 +01:00
Manuel Rüger 22067a0295 tools: Switch from benchcmp to benchstat
benchcmp is deprecated and thus replaced by benchstat

Signed-off-by: Manuel Rüger <manuel@rueg.eu>
2022-02-05 18:42:17 +01:00
Brad Ison d01ad03ae6
Use v1 PodDisruptionBudget and CronJob resources
Both the PodDisruptionBudget and CronJob resources have been promoted
to v1 as of Kubernetes v1.21 release.  The previous v1beta1 versions
are now deprecated, and will be removed in v1.25 and above.  This
updates all references to the new v1 versions.
2022-01-04 14:47:41 +01:00
fpetkovski 456c6c2193 Prepare 2.3.0 2021-12-09 15:13:03 +01:00
Manuel Rüger 2e78af1ccd Fix findings to make lint pass
Signed-off-by: Manuel Rüger <manuel@rueg.eu>
2021-11-18 16:22:16 +01:00
Olivier Lemasle ce2116679e e2e TestDefaultCollectorMetricsAvailable improvements:
- Remove usage of deprecated io/ioutil
- Comply to PR comments
2021-10-18 17:03:41 +02:00
YaoZengzeng eb9aeb35d8 [e2e] check all default collector metrics are available
Signed-off-by: YaoZengzeng <yaozengzeng@huawei.com>
2021-10-18 15:25:14 +02:00
Manuel Rüger e3f0cbde58 Support Kubernetes 1.22.0 2021-08-05 14:21:13 +02:00
Schlotter, Christian d1a8f317a3 tests/e2e/main_test.go use new promlint package and drop github.com/prometheus/prometheus dependency
Signed-off-by: Schlotter, Christian <christian.schlotter@daimler.com>
2021-07-14 10:43:18 +02:00
Manuel Rüger 9546b02244 tests/e2e.sh: Test with kind 0.11.0 & k8s 1.21.1 2021-05-18 23:07:42 +02:00
Tariq Ibrahim 595781345c
Merge pull request #1466 from kubernetes/no-helm-cd
[helm] remove github actions for helm continuous deploys
2021-04-27 15:23:21 -07:00
Tariq Ibrahim 5f20487137
[helm] remove github actions for helm continuous deploys 2021-04-27 15:14:28 -07:00