Liking cljdoc? Tell your friends :D

congestion.quota-state


QuotaStatecljprotocol

build-error-responseclj

(build-error-response self response-builder)

increment-counterclj

(increment-counter self storage)

quota-exhausted?clj

(quota-exhausted? self)

rate-limit-responseclj

(rate-limit-response self rsp)
source

read-quota-stateclj

(read-quota-state storage limit req)

Read the quota state from storage.

Generates a storage key from the limit and the ring request. If the key is nil, the request will not be rate-limited. Otherwise looks up the current counter value from storage and based on the counter the quota state is either exhausted or available.

Read the quota state from storage.

Generates a storage key from the limit and the ring request. If the
key is `nil`, the request will not be rate-limited. Otherwise looks
up the current counter value from storage and based on the counter
the quota state is either exhausted or available.
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close