Documentation
¶
Overview ¶
Package errors provides HTTP-specific error helpers for go-service.
This package contains small helpers for classifying and normalizing HTTP-related errors.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ServerError ¶
ServerError normalizes expected HTTP server shutdown errors.
The standard library returns http.ErrServerClosed from (*http.Server).Serve / ServeTLS when the server is shut down normally via (*http.Server).Shutdown or Close. In many go-service components this is not considered a real error and should not be surfaced as a startup/serve failure.
ServerError returns nil when err is http.ErrServerClosed, otherwise it returns err unchanged.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.