Skip to content

Commit 41ed8a6

Browse files
committed
fix: Fix the parsing of the --throttle-timeout command line arg
1 parent 4b1b153 commit 41ed8a6

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

internal/controllers/gateway.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ func NewGatewayController(mgr manager.Manager, ch event.EventChannel, log logr.L
127127
}
128128
r.log.Info("Watching dataplane Deployment objects")
129129

130-
// watch Deployment objects referenced by one of our Gateways
130+
// watch DaemonSet objects referenced by one of our Gateways
131131
if err := c.Watch(
132132
source.Kind(mgr.GetCache(), &appv1.DaemonSet{},
133133
&handler.TypedEnqueueRequestForObject[*appv1.DaemonSet]{},

main.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -155,11 +155,12 @@ func main() {
155155
setupLog.Info("config discovery server", "local-addr", cdsAddr,
156156
"remote-addr", config.ConfigDiscoveryAddress)
157157

158-
if d, err := time.ParseDuration(throttleTimeout); err != nil {
159-
setupLog.Info("setting rate-limiting (throttle timeout)", "timeout", throttleTimeout)
158+
if d, err := time.ParseDuration(throttleTimeout); err == nil {
160159
config.ThrottleTimeout = d
161160
}
162161

162+
setupLog.V(1).Info("setting rate-limiting (throttle timeout)", "timeout", config.ThrottleTimeout.String())
163+
163164
setupLog.Info("setting up Kubernetes controller manager")
164165

165166
mgr, err := ctrl.NewManager(ctrl.GetConfigOrDie(), ctrl.Options{

0 commit comments

Comments
 (0)