Skip to content

Commit

Permalink
api: add call duration in logs
Browse files Browse the repository at this point in the history
  • Loading branch information
Quentin-M authored and jzelinskie committed Feb 24, 2016
1 parent 06531e0 commit 8d76700
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion api/context/context.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ func HTTPHandler(handler Handler, ctx *RouteContext) httprouter.Handle {
}
utils.PrometheusObserveTimeMilliseconds(promResponseDurationMilliseconds.WithLabelValues(route, statusStr), start)

log.Infof("%s \"%s %s\" %s", r.RemoteAddr, r.Method, r.RequestURI, statusStr)
log.Infof("%s \"%s %s\" %s (%s)", r.RemoteAddr, r.Method, r.RequestURI, statusStr, time.Since(start))
}
}

Expand Down

0 comments on commit 8d76700

Please sign in to comment.