From 9be5904ead41addaa625bb88c7eda7b7ebc5aaba Mon Sep 17 00:00:00 2001 From: Tatsuhiro Tsujikawa Date: Wed, 7 Feb 2024 03:20:24 +0000 Subject: [PATCH] Mark endpoint-slices flag as deprecated --- cmd/nghttpx-ingress-controller/main.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cmd/nghttpx-ingress-controller/main.go b/cmd/nghttpx-ingress-controller/main.go index cc6e0d3a..71273a6d 100644 --- a/cmd/nghttpx-ingress-controller/main.go +++ b/cmd/nghttpx-ingress-controller/main.go @@ -171,6 +171,9 @@ func main() { `Specify namespace/name of Service whose hostnames/IP addresses are set in Ingress resource instead of addresses of Ingress controller Pods. Takes the form namespace/name.`) rootCmd.Flags().BoolVar(&endpointSlices, "endpoint-slices", endpointSlices, `(Deprecated) Get endpoints from EndpointSlice resource instead of Endpoints resource. EndpointSlice resource is always used regardless of this flag. Usage of Endpoints resource has been removed.`) + if err := rootCmd.Flags().MarkDeprecated("endpoint-slices", "stop using it"); err != nil { + panic(err) + } rootCmd.Flags().Float64Var(&reloadRate, "reload-rate", reloadRate, `Rate (QPS) of reloading nghttpx configuration to deal with frequent backend updates in a single batch.`)