From dd9721057a724af98de7ec98dcb38e73b9f708a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Giedrius=20Statkevi=C4=8Dius?= Date: Thu, 23 Apr 2020 18:19:57 +0300 Subject: [PATCH 1/2] cmd: rule: do not wrap reload endpoint with '/' MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Do not wrap the router with `/` on the `/-/reload` endpoint. Otherwise, it is inaccessible when no prefix has been specified by the user. Signed-off-by: Giedrius Statkevičius --- cmd/thanos/rule.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/thanos/rule.go b/cmd/thanos/rule.go index 33889f7c99..d49409627b 100644 --- a/cmd/thanos/rule.go +++ b/cmd/thanos/rule.go @@ -561,7 +561,7 @@ func runRule( router = router.WithPrefix(webRoutePrefix) } - router.WithPrefix(webRoutePrefix).Post("/-/reload", func(w http.ResponseWriter, r *http.Request) { + router.Post("/-/reload", func(w http.ResponseWriter, r *http.Request) { reloadMsg := make(chan error) reloadWebhandler <- reloadMsg if err := <-reloadMsg; err != nil { From 7f7f6e7c605b8a75e332f9a0e7ef6967d7273850 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Giedrius=20Statkevi=C4=8Dius?= Date: Thu, 23 Apr 2020 18:22:19 +0300 Subject: [PATCH 2/2] CHANGELOG: update MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Giedrius Statkevičius --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index bf19725f45..828e2d4b7f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,6 +14,7 @@ We use *breaking* word for marking changes that are not backward compatible (rel ### Fixed - [#2501](https://github.com/thanos-io/thanos/pull/2501) Query: gracefully handle additional fields in `SeriesResponse` protobuf message that may be added in the future. +- [#2515](https://github.com/thanos-io/thanos/pull/2515) Rule: do not wrap reload endpoint with `/`. Makes `/-/reload` accessible again when no prefix has been specified. ### Added