Carl Bergquist
f2f2722bb1
chore: avoid aliasing models in middleware ( #22484 )
2020-02-28 12:50:58 +01:00
Marcus Efraimsson
fd52570b7f
API: Improve recovery middleware when response already been written ( #22256 )
...
Suppresses stacktrace in recovery middleware if error is
http.ErrAbortHandler.
Skips writing response error in recovery middleware if
resoonse have already been written.
Skips try rotate of auth token if response have already
been written.
Skips adding default response headers if response have
already been written.
Fixes #15728
Ref #18082
Co-Authored-By: Arve Knudsen <arve.knudsen@gmail.com>
2020-02-18 22:53:40 +01:00
zhulongcheng
2fff8f77dc
move log package to /infra ( #17023 )
...
ref #14679
Signed-off-by: zhulongcheng <zhulongcheng.me@gmail.com>
2019-05-13 08:45:54 +02:00
Torkel Ödegaard
34c70ca7ce
fix for issue with error view in production builds
2018-11-20 13:47:45 +01:00
Torkel Ödegaard
b415d82611
fixed to template PR issues, #13938
2018-11-02 10:49:46 +01:00
Mario Trangoni
91fb2e07ce
pkg: fix codespell issues
2018-04-13 20:31:29 +02:00
Dan Cech
c0ecdee375
rename Context to ReqContext
2018-03-07 11:54:50 -05:00
Dan Cech
338655dd37
move Context and session out of middleware
2018-03-06 18:16:49 -05:00
bergquist
842f4c1d32
tech: dont print error message on 500 page
...
closes #10828
2018-02-14 16:39:20 +01:00
Torkel Ödegaard
0e61a670bb
fix: error handling now displays page correctly, fixes #10777
2018-02-06 12:28:17 +01:00
Daniel Lee
0d85c63fff
middleware: recovery handles panics in all handlers
...
Also, changes the order of the middleware so that recovery is after the
gzip middleware. Otherwise, a 200 OK is returned instead of a 500 error.
2017-11-15 13:57:33 +01:00
Torkel Ödegaard
18e965c775
fix(error handling): fixed server side error handling page
2016-11-16 17:41:44 +01:00
Torkel Ödegaard
3dc7706c45
feat(loggin): improved http request panic handling
2016-06-07 10:05:10 +02:00