LeakyBucketOptions
@discordeno/utils • Docs
Documentation / @discordeno/utils / LeakyBucketOptions
Interface: LeakyBucketOptions
Properties
logger?
optional
logger:Pick
<object
,"debug"
|"info"
|"warn"
|"error"
|"fatal"
>
The logger that the leaky bucket will use
Type declaration
debug()
debug: (...
args
) =>void
Parameters
• ...args: any
[]
Returns
void
error()
error: (...
args
) =>void
Parameters
• ...args: any
[]
Returns
void
fatal()
fatal: (...
args
) =>void
Parameters
• ...args: any
[]
Returns
void
info()
info: (...
args
) =>void
Parameters
• ...args: any
[]
Returns
void
log()
log: (
level
, ...args
) =>void
Parameters
• level: LogLevels
• ...args: any
[]
Returns
void
setDepth()
setDepth: (
level
) =>void
Parameters
• level: LogDepth
Returns
void
setLevel()
setLevel: (
level
) =>void
Parameters
• level: LogLevels
Returns
void
warn()
warn: (...
args
) =>void
Parameters
• ...args: any
[]
Returns
void
Default
logger // The logger exported by @discordeno/utils
Defined in
packages/utils/src/bucket.ts:139
max?
optional
max:number
Max requests allowed at once.
Default
1
Defined in
packages/utils/src/bucket.ts:124
refillAmount?
optional
refillAmount:number
Amount of requests to refill at each interval.
Default
1
Defined in
packages/utils/src/bucket.ts:134
refillInterval?
optional
refillInterval:number
Interval in milliseconds between refills.
Default
5000