mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
live: better error logging in push API (#36601)
This commit is contained in:
parent
d4a990215f
commit
e1358eeb76
@ -89,6 +89,7 @@ func (g *Gateway) Handle(ctx *models.ReqContext) {
|
||||
for _, mf := range metricFrames {
|
||||
err := stream.Push(ctx.SignedInUser.OrgId, mf.Key(), mf.Frame())
|
||||
if err != nil {
|
||||
logger.Error("Error pushing frame", "error", err, "data", string(body))
|
||||
ctx.Resp.WriteHeader(http.StatusInternalServerError)
|
||||
return
|
||||
}
|
||||
|
@ -191,6 +191,7 @@ func (s *Handler) ServeHTTP(rw http.ResponseWriter, r *http.Request) {
|
||||
for _, mf := range metricFrames {
|
||||
err := stream.Push(user.OrgId, mf.Key(), mf.Frame())
|
||||
if err != nil {
|
||||
logger.Error("Error pushing frame", "error", err, "data", string(body))
|
||||
return
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user