Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GracefulShutdownServerOnSignal ¶
func GracefulShutdownServerOnSignal(server *http.Server, signalLog, errorLog Logger, timeout time.Duration, signals ...os.Signal)
GracefulShutdownServerOnSignal shuts down the passed server gracefully after the process was notified with any of the passed signals. The server is guaranteed to shut down with the passed timeout after a signal. A timeout value of zero disables the timeout. If no signals are passed, then SIGHUP, SIGINT, SIGTERM will be used. If signalLog is not nil, then the received signal will be logged with it. If errorLog is not nil, then any errors from the server shutdown will be logged with it.
Types ¶
Directories
¶
Path | Synopsis |
---|---|
Package contenttype exports MIME content-type constants.
|
Package contenttype exports MIME content-type constants. |
Click to show internal directories.
Click to hide internal directories.