The interval set on creation of this Limiter
Allows to sample, change or react to changes to the current interval between two tasks.
Obtains a snapshot of the current number of jobs waiting to be executed.
Obtains a snapshot of the current number of jobs waiting to be executed. May be out of date the instant after it is retrieved.
Returns an F[Unit]
which represents the action of submitting
job
to the limiter with the given priority.
Returns an F[Unit]
which represents the action of submitting
job
to the limiter with the given priority. A higher
number means a higher priority. The default is 0.
The semantics of submit
are fire-and-forget: the returned
F[Unit]
immediately returns, without waiting for the F[A]
to complete its execution. Note that this means that the
returned F[Unit]
will be successful regardless of whether
job
fails or not.
This method is designed to be called concurrently: every concurrent call submits a job, and they are all started at a rate which is no higher then the maximum rate you specify when constructing a Limiter. Higher priority jobs take precedence over lower priority ones.
A purely functional, interval based rate limiter.