Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Arg ¶
type Arg struct {
// contains filtered or unexported fields
}
Arg captures path components and attaches them to the request context. It always captures a non-empty component.
type Dir ¶
Dir pulls off path components from the front of the path and dispatches. It attempts to dispatch to "*" without consuming a path component if nothing matches.
type Resources ¶
type Resources struct {
// contains filtered or unexported fields
}
Resources wrap a database and expose methods over HTTP.
func New ¶
func New( log *zap.Logger, db *authdb.Database, endpoint *url.URL, authToken []string, postSizeLimit memory.Size, ) *Resources
New constructs Resources for some database. If getAccessRL is nil then GetAccess endpoint won't be rate-limited.
func (*Resources) ServeHTTP ¶
func (res *Resources) ServeHTTP(w http.ResponseWriter, req *http.Request)
ServeHTTP makes Resources an http.Handler.
func (*Resources) SetShutdown ¶
func (res *Resources) SetShutdown()
SetShutdown sets the inShutdown status flag to true indicating the server is shutting down.
func (*Resources) SetStartupDone ¶
func (res *Resources) SetStartupDone()
SetStartupDone sets the startup status flag to true indicating startup is complete.