File tree Expand file tree Collapse file tree 1 file changed +1
-12
lines changed
staging/src/k8s.io/apiserver/pkg/server/filters Expand file tree Collapse file tree 1 file changed +1
-12
lines changed Original file line number Diff line number Diff line change @@ -25,17 +25,6 @@ import (
25
25
"k8s.io/apiserver/pkg/server/httplog"
26
26
)
27
27
28
- func badHTTPResponse () httplog.StacktracePred {
29
- return func (status int ) bool {
30
- // http status code should not be zero
31
- if status == 0 {
32
- klog .Errorf ("Bad HTTP Response - status is zero" )
33
- return true
34
- }
35
- return false
36
- }
37
- }
38
-
39
28
// WithPanicRecovery wraps an http Handler to recover and log panics.
40
29
func WithPanicRecovery (handler http.Handler ) http.Handler {
41
30
return withPanicRecovery (handler , func (w http.ResponseWriter , req * http.Request , err interface {}) {
@@ -50,7 +39,7 @@ func withPanicRecovery(handler http.Handler, crashHandler func(http.ResponseWrit
50
39
crashHandler (w , req , err )
51
40
})
52
41
53
- logger := httplog .NewLogged (req , & w ). StacktraceWhen ( badHTTPResponse ())
42
+ logger := httplog .NewLogged (req , & w )
54
43
defer logger .Log ()
55
44
56
45
// Dispatch to the internal handler
You can’t perform that action at this time.
0 commit comments