Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type QuantityLimiter ¶
type QuantityLimiter struct { // Prefix to be used for GET parameters for set and get tokens. ParameterNamePrefix string `json:"parameterNamePrefix,omitempty"` // Number of successful requests that can be made using a token. Quantity uint64 `json:"quantity,omitempty"` // contains filtered or unexported fields }
QuantityLimiter limits the number of successful requests for a token and allows the counter to be reset.
func (QuantityLimiter) CaddyModule ¶
func (QuantityLimiter) CaddyModule() caddy.ModuleInfo
func (*QuantityLimiter) Provision ¶
func (ql *QuantityLimiter) Provision(ctx caddy.Context) error
func (QuantityLimiter) ServeHTTP ¶
func (ql QuantityLimiter) ServeHTTP(w http.ResponseWriter, r *http.Request, next caddyhttp.Handler) error
func (*QuantityLimiter) UnmarshalCaddyfile ¶
func (ql *QuantityLimiter) UnmarshalCaddyfile(d *caddyfile.Dispenser) error
Click to show internal directories.
Click to hide internal directories.