From 882b4b2d230f460f4e5b35049520798f4a3d667b Mon Sep 17 00:00:00 2001 From: stefanprodan Date: Tue, 8 Jan 2019 13:15:10 +0200 Subject: [PATCH] Update the control loop interval flag description --- cmd/flagger/main.go | 2 +- docs/gitbook/how-it-works.md | 2 +- pkg/controller/scheduler.go | 2 ++ 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/cmd/flagger/main.go b/cmd/flagger/main.go index 750c6a18a..7b7dd2e35 100644 --- a/cmd/flagger/main.go +++ b/cmd/flagger/main.go @@ -37,7 +37,7 @@ func init() { flag.StringVar(&kubeconfig, "kubeconfig", "", "Path to a kubeconfig. Only required if out-of-cluster.") flag.StringVar(&masterURL, "master", "", "The address of the Kubernetes API server. Overrides any value in kubeconfig. Only required if out-of-cluster.") flag.StringVar(&metricsServer, "metrics-server", "http://prometheus:9090", "Prometheus URL") - flag.DurationVar(&controlLoopInterval, "control-loop-interval", 10*time.Second, "wait interval between rollouts") + flag.DurationVar(&controlLoopInterval, "control-loop-interval", 10*time.Second, "Kubernetes API sync interval") flag.StringVar(&logLevel, "log-level", "debug", "Log level can be: debug, info, warning, error.") flag.StringVar(&port, "port", "8080", "Port to listen on.") flag.StringVar(&slackURL, "slack-url", "", "Slack hook URL.") diff --git a/docs/gitbook/how-it-works.md b/docs/gitbook/how-it-works.md index f64964975..00adeef47 100644 --- a/docs/gitbook/how-it-works.md +++ b/docs/gitbook/how-it-works.md @@ -154,7 +154,7 @@ You can determine the minimum time that it takes to validate and promote a canar interval * (maxWeight / stepWeight) ``` -And the time it takes for a canary to be rollback: +And the time it takes for a canary to be rollback when the metrics or webhook checks are failing: ``` interval * threshold diff --git a/pkg/controller/scheduler.go b/pkg/controller/scheduler.go index 6e496eba6..8608d2bba 100644 --- a/pkg/controller/scheduler.go +++ b/pkg/controller/scheduler.go @@ -17,6 +17,8 @@ func (c *Controller) scheduleCanaries() { c.canaries.Range(func(key interface{}, value interface{}) bool { canary := value.(*flaggerv1.Canary) + + // format: . name := key.(string) current[name] = true