mirror of
https://github.com/VictoriaMetrics/VictoriaMetrics.git
synced 2025-01-10 15:14:09 +00:00
app/vmselect/prometheus: fix content-type for /api/v1/export
responses
The correct Content-Type should be `application/stream+json` instead of `application/json` Thanks to Joshua Ryder for pointing to this.
This commit is contained in:
parent
28cc4c09b5
commit
e0ac068112
1 changed files with 1 additions and 1 deletions
|
@ -154,7 +154,7 @@ var exportDuration = metrics.NewSummary(`vm_request_duration_seconds{path="/api/
|
|||
func exportHandler(at *auth.Token, w http.ResponseWriter, matches []string, start, end int64, format string, deadline netstorage.Deadline) error {
|
||||
writeResponseFunc := WriteExportStdResponse
|
||||
writeLineFunc := WriteExportJSONLine
|
||||
contentType := "application/json"
|
||||
contentType := "application/stream+json"
|
||||
if format == "prometheus" {
|
||||
contentType = "text/plain"
|
||||
writeLineFunc = WriteExportPrometheusLine
|
||||
|
|
Loading…
Reference in a new issue