Skip to content

Commit

Permalink
Merge pull request kubernetes#1240 from brendandburns/http
Browse files Browse the repository at this point in the history
Don't stack trace on 301s
  • Loading branch information
lavalamp committed Sep 9, 2014
2 parents 5bb9495 + 69b359b commit a4e3a4e
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions pkg/apiserver/apiserver.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,10 @@ type defaultAPIServer struct {
group *APIGroup
}

const (
StatusUnprocessableEntity = 422
)

// Handle returns a Handler function that expose the provided storage interfaces
// as RESTful resources at prefix, serialized by codec, and also includes the support
// http resources.
Expand Down Expand Up @@ -126,9 +130,11 @@ func RecoverPanics(handler http.Handler) http.Handler {
httplog.StatusIsNot(
http.StatusOK,
http.StatusAccepted,
http.StatusMovedPermanently,
http.StatusTemporaryRedirect,
http.StatusConflict,
http.StatusNotFound,
StatusUnprocessableEntity,
),
).Log()

Expand Down

0 comments on commit a4e3a4e

Please sign in to comment.