Documentation ¶
Index ¶
Constants ¶
View Source
const ( ErrClientCanceled = "The request was cancelled by the client." ErrDeadlineExceeded = "" /* 160-byte string literal not displayed */ )
View Source
const StatusClientClosedRequest = 499
StatusClientClosedRequest is the status code for when a client request cancellation of an http request
Variables ¶
This section is empty.
Functions ¶
func ClientHTTPStatusAndError ¶
ClientHTTPStatusAndError returns error and http status that is "safe" to return to client without exposing any implementation details.
func Error ¶
func Error(w http.ResponseWriter, err error)
Error write a go error with the correct status code.
func ErrorWithStatus ¶
func ErrorWithStatus(w http.ResponseWriter, err error, status int)
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.