You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using net/http/httputil ReverseProxy where the upstream server is, for example, refusing connections the HTTP status code returned is StatusInternalServerError. It would be more appropriate (and helpful to the client) to return StatusBadGateway.
Looking at the underlying code for http.Transport, it looks like there is no way to differentiate between the two classes of error at the moment.
The text was updated successfully, but these errors were encountered:
minux
changed the title
ReverseProxy error 500
net/http/httputil: ReverseProxy should use StatusBadGateway if backend can't be connected
Feb 14, 2015
When using
net/http/httputil
ReverseProxy where the upstream server is, for example, refusing connections the HTTP status code returned isStatusInternalServerError
. It would be more appropriate (and helpful to the client) to returnStatusBadGateway
.Looking at the underlying code for http.Transport, it looks like there is no way to differentiate between the two classes of error at the moment.
The text was updated successfully, but these errors were encountered: