View Source Fast.RateLimiter (Fast v0.9.0)

Wrapper around ExRated that allows env based config.

Link to this section Summary

Link to this section Functions

Link to this function

check_rate(bucket_id, window_ms, max_num_calls)

View Source
@spec check_rate(String.t(), non_neg_integer(), non_neg_integer()) ::
  {:ok, :disabled | non_neg_integer()} | {:error, non_neg_integer()}
@spec reset(String.t()) :: :ok