Skip to content

Commit

Permalink
Remove mention of Mimir-specific HTTP header (#736)
Browse files Browse the repository at this point in the history
Signed-off-by: Nick Pillitteri <nick.pillitteri@grafana.com>
  • Loading branch information
56quarters authored Jan 12, 2022
1 parent 3722354 commit a39b5c7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
5 changes: 2 additions & 3 deletions docs/configuration/config-file-reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,9 +76,8 @@ api:

# Allows to skip label name validation via header on the http write path. Use
# with caution as it breaks PromQL. Allowing this for external clients allows
# any client to send invalid label names. After enabling it, requests with
# X-Mimir-SkipLabelNameValidation HTTP header set to true will not have label
# names validated.
# any client to send invalid label names. After enabling it, requests with a
# specific HTTP header set to true will not have label names validated.
# CLI flag: -api.skip-label-name-validation-header-enabled
[skip_label_name_validation_header_enabled: <boolean> | default = false]

Expand Down
3 changes: 2 additions & 1 deletion pkg/api/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,8 @@ type Config struct {
// RegisterFlags adds the flags required to config this to the given FlagSet.
func (cfg *Config) RegisterFlags(f *flag.FlagSet) {
f.BoolVar(&cfg.ResponseCompression, "api.response-compression-enabled", false, "Use GZIP compression for API responses. Some endpoints serve large YAML or JSON blobs which can benefit from compression.")
f.BoolVar(&cfg.SkipLabelNameValidationHeader, "api.skip-label-name-validation-header-enabled", false, "Allows to skip label name validation via header on the http write path. Use with caution as it breaks PromQL. Allowing this for external clients allows any client to send invalid label names. After enabling it, requests with X-Mimir-SkipLabelNameValidation HTTP header set to true will not have label names validated.")
// TODO(56quarters): Mention the specific header "X-Mimir-SkipLabelNameValidation" after Mimir is public
f.BoolVar(&cfg.SkipLabelNameValidationHeader, "api.skip-label-name-validation-header-enabled", false, "Allows to skip label name validation via header on the http write path. Use with caution as it breaks PromQL. Allowing this for external clients allows any client to send invalid label names. After enabling it, requests with a specific HTTP header set to true will not have label names validated.")
cfg.RegisterFlagsWithPrefix("", f)
}

Expand Down

0 comments on commit a39b5c7

Please sign in to comment.