-
Notifications
You must be signed in to change notification settings - Fork 1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make caser a local varialbe, not a global one.
The cases.Caser returned by calling cases.Title *cannot* be shared among goroutines. This might happen when Prometheus tries to scrape multiple targets at the same time. From the docs: A Caser may be stateful and should therefore not be shared between goroutines. Fixes: #922 Signed-off-by: Marcelo E. Magallon <marcelo.magallon@grafana.com>
- Loading branch information
1 parent
148a9de
commit 54ed14c
Showing
2 changed files
with
13 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters