Documentation ¶
Overview ¶
Package idledown provides an htadaptor.Middleware that shuts the server down due to inactivity.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func New ¶ added in v0.0.12
func New( parent context.Context, shutdownAfter time.Duration, ) (context.Context, htadaptor.Middleware)
New creates an htadaptor.Middleware that resets its internal timer for each http.Request and shuts down an http.Server when the timer runs out. Use it for services that are meant to scale down to zero or few instances.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.