From 58a54e7b73c8b723581f7ec8658796ca94779a7b Mon Sep 17 00:00:00 2001 From: Wing924 Date: Tue, 25 Aug 2020 17:37:27 +0900 Subject: [PATCH 1/5] Fixes `-config.expand-env` requires argument. Fixes #3082 Signed-off-by: Wing924 --- CHANGELOG.md | 1 + cmd/cortex/main.go | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8ba21124253..4906e6c6598 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -29,6 +29,7 @@ * [BUGFIX] Fix configuration for TLS server validation, TLS skip verify was hardcoded to true for all TLS configurations and prevented validation of server certificates. #3030 * [BUGFIX] Fixes the Alertmanager panicking when no `-alertmanager.web.external-url` is provided. #3017 * [BUGFIX] Fixes the registration of the Alertmanager API metrics `cortex_alertmanager_alerts_received_total` and `cortex_alertmanager_alerts_invalid_total`. #3065 +* [BUGFIX] Fixes `-config.expand-env` requires argument. ## 1.3.0 / 2020-08-21 diff --git a/cmd/cortex/main.go b/cmd/cortex/main.go index 9602d098dbc..371084e05a5 100644 --- a/cmd/cortex/main.go +++ b/cmd/cortex/main.go @@ -80,7 +80,7 @@ func main() { // Ignore -config.file and -config.expand-env here, since it was already parsed, but it's still present on command line. flagext.IgnoredFlag(flag.CommandLine, configFileOption, "Configuration file to load.") - flagext.IgnoredFlag(flag.CommandLine, configExpandENV, "Expands ${var} or $var in config according to the values of the environment variables.") + _ = flag.CommandLine.Bool(configExpandENV, false, "Expands ${var} or $var in config according to the values of the environment variables.") flag.IntVar(&eventSampleRate, "event.sample-rate", 0, "How often to sample observability events (0 = never).") flag.IntVar(&ballastBytes, "mem-ballast-size-bytes", 0, "Size of memory ballast to allocate.") From f121b61e624c4e7a511cb69b112c236100f8deef Mon Sep 17 00:00:00 2001 From: Wing924 Date: Tue, 25 Aug 2020 17:42:32 +0900 Subject: [PATCH 2/5] fix Signed-off-by: Wing924 --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4906e6c6598..0ad37a55379 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -29,7 +29,7 @@ * [BUGFIX] Fix configuration for TLS server validation, TLS skip verify was hardcoded to true for all TLS configurations and prevented validation of server certificates. #3030 * [BUGFIX] Fixes the Alertmanager panicking when no `-alertmanager.web.external-url` is provided. #3017 * [BUGFIX] Fixes the registration of the Alertmanager API metrics `cortex_alertmanager_alerts_received_total` and `cortex_alertmanager_alerts_invalid_total`. #3065 -* [BUGFIX] Fixes `-config.expand-env` requires argument. +* [BUGFIX] Fixes `-config.expand-env` requires argument. #3083 ## 1.3.0 / 2020-08-21 From a91330e04862b08e650d778b42b2eb4c53e782db Mon Sep 17 00:00:00 2001 From: Wing924 Date: Fri, 11 Dec 2020 19:14:52 +0900 Subject: [PATCH 3/5] Query-Frontend: cortex_query_seconds_total now return seconds not nanoseconds. Signed-off-by: Wing924 --- CHANGELOG.md | 1 + pkg/frontend/transport/handler.go | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 1a1193fe5fe..10f6ba34d2d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,7 @@ ## master / unreleased * [ENHANCEMENT] Memberlist: add status page with available details about memberlist-based KV store and memberlist cluster. It's also possible to view KV values in Go struct or JSON format, or download for inspection. #3575 +* [BUGFIX] Query-Frontend: `cortex_query_seconds_total` now return seconds not nanoseconds. ## 1.6.0-rc.0 in progress diff --git a/pkg/frontend/transport/handler.go b/pkg/frontend/transport/handler.go index f3a8d3fc311..a043588e89f 100644 --- a/pkg/frontend/transport/handler.go +++ b/pkg/frontend/transport/handler.go @@ -152,7 +152,7 @@ func (f *Handler) reportQueryStats(r *http.Request, queryString url.Values, quer } // Track stats. - f.querySeconds.WithLabelValues(userID).Add(float64(stats.LoadWallTime())) + f.querySeconds.WithLabelValues(userID).Add(stats.LoadWallTime().Seconds()) // Log stats. logMessage := append([]interface{}{ From e606b1027ec6c7ca919e66fa4abe9c2a93d637be Mon Sep 17 00:00:00 2001 From: Wing924 Date: Fri, 11 Dec 2020 19:18:37 +0900 Subject: [PATCH 4/5] fix Signed-off-by: Wing924 --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 10f6ba34d2d..87017f10d01 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,7 +3,7 @@ ## master / unreleased * [ENHANCEMENT] Memberlist: add status page with available details about memberlist-based KV store and memberlist cluster. It's also possible to view KV values in Go struct or JSON format, or download for inspection. #3575 -* [BUGFIX] Query-Frontend: `cortex_query_seconds_total` now return seconds not nanoseconds. +* [BUGFIX] Query-Frontend: `cortex_query_seconds_total` now return seconds not nanoseconds. #3589 ## 1.6.0-rc.0 in progress From ced0170bb6f53f3e46d27ffda96832af8650ab0d Mon Sep 17 00:00:00 2001 From: Marco Pracucci Date: Fri, 11 Dec 2020 12:11:56 +0100 Subject: [PATCH 5/5] Update CHANGELOG.md Signed-off-by: Marco Pracucci --- CHANGELOG.md | 1 - 1 file changed, 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index dbda7f23153..66e57790060 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,7 +2,6 @@ ## master / unreleased -* [ENHANCEMENT] Memberlist: add status page with available details about memberlist-based KV store and memberlist cluster. It's also possible to view KV values in Go struct or JSON format, or download for inspection. #3575 * [BUGFIX] Query-Frontend: `cortex_query_seconds_total` now return seconds not nanoseconds. #3589 * [ENHANCEMENT] Memberlist: add status page (/memberlist) with available details about memberlist-based KV store and memberlist cluster. It's also possible to view KV values in Go struct or JSON format, or download for inspection. #3575 * [ENHANCEMENT] Memberlist: client can now keep a size-bounded buffer with sent and received messages and display them in the admin UI (/memberlist) for troubleshooting. #3581