mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2026-11-16 08:45:22 +01:00
helm: drop the 4.53 vector metrics render guard (#12672)
* helm: pin the 4.53 tag in the vector metrics rejection test The 4.54 release made 4.54 the chart's default image, and that image serves weed-vector metrics, so rendering vector.metricsPort with the default tag no longer fails. Pin image.tag=4.53 for the rejection case and check that the default image renders the metrics port. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * helm: describe vector metrics support from 4.54 on in the chart README Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * helm: say the vector metrics render guard skips image overrides Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * helm: drop the 4.53 vector metrics render guard The chart now defaults to 4.54, whose weed-vector serves --metrics-port, so the check keyed on one old tag only blocked valid installs. The test asserts the default image renders the metrics flag and HTTP probes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * helm: describe vector metrics without the render guard in the chart README Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
5ef99c1d8d
commit
d5b4e1352e
3 files changed
+7
-12
No files matched your search
@@ -718,7 +718,7 @@ The bundled engine images support Linux amd64 and arm64. Use `vector.imageOverri
|
||||
|
||||
`global.seaweedfs.enableSecurity` provisions and mounts the vector certificate and shared security configuration. With external certificates, provide the `<fullname>-vector-cert` secret (`my-seaweedfs-vector-cert` for release `my`). `fullname` follows `seaweedfs.fullname`, including `fullnameOverride`, `nameOverride`, and DNS-name truncation. Provide this secret alongside the existing CA and client secrets.
|
||||
|
||||
The default `vector.metricsPort: 0` and TCP probes support existing engine images. The default 4.53 image does not accept metrics flags; enabling metrics with it is rejected at render time. For engine builds with `/metrics`, `/health`, and `/ready`, set `vector.imageOverride` to that compatible image and `vector.metricsPort: 9329`; readiness then checks master registration. Enabling `global.seaweedfs.monitoring.enabled` also creates the vector ServiceMonitor. NetworkPolicy includes the configured gRPC and metrics ports.
|
||||
The default `vector.metricsPort: 0` keeps TCP probes. Set `vector.metricsPort: 9329` to serve `/metrics`, `/health`, and `/ready` from the engine; readiness then checks master registration. Images older than 4.54 do not accept the metrics flag, so leave metrics off when pinning `image.tag` or `vector.imageOverride` to one. Enabling `global.seaweedfs.monitoring.enabled` also creates the vector ServiceMonitor. NetworkPolicy includes the configured gRPC and metrics ports.
|
||||
|
||||
|
||||
To provision vector buckets during installation and upgrades, set:
|
||||
|
||||
@@ -1,8 +1,5 @@
|
||||
{{- include "seaweedfs.compat" . -}}
|
||||
{{- if .Values.vector.enabled }}
|
||||
{{- if and .Values.vector.metricsPort (not .Values.vector.imageOverride) (eq (toString (.Values.image.tag | default .Chart.AppVersion)) "4.53") }}
|
||||
{{- fail "vector.metricsPort requires vector.imageOverride selecting an engine with metrics support; the default 4.53 image does not support metrics" }}
|
||||
{{- end }}
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
|
||||
@@ -136,13 +136,11 @@ func TestVectorNetworkPolicyOverrides(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
func TestVectorMetricsImageCompatibility(t *testing.T) {
|
||||
if _, err := exec.LookPath("helm"); err != nil {
|
||||
t.Skip("helm is not installed")
|
||||
func TestVectorMetricsDefaultImage(t *testing.T) {
|
||||
output, _ := render(t, "vector.enabled=true", "vector.metricsPort=9329")
|
||||
for _, want := range []string{"--metrics-port=9329", "path: /ready", "path: /health"} {
|
||||
if !strings.Contains(output, want) {
|
||||
t.Fatalf("default image missing %q", want)
|
||||
}
|
||||
}
|
||||
out, err := exec.Command("helm", "template", "vector-test", "..", "--set", "vector.enabled=true", "--set", "vector.metricsPort=9329").CombinedOutput()
|
||||
if err == nil || !strings.Contains(string(out), "default 4.53 image does not support metrics") {
|
||||
t.Fatalf("incompatible image accepted: %v %s", err, out)
|
||||
}
|
||||
render(t, "vector.enabled=true", "vector.metricsPort=9329", "vector.imageOverride=example/metrics-engine:test")
|
||||
}
|
||||
Reference in new issue
Block a user