Throttler
Last updated
Last updated
[flow/Throttler]
Throttles the received signal, forwarding only count
number of signals in delay
milliseconds.
Reports internal buffer size via buffer size
.
Example:
delay
set to 3000, count
set to 1
A@1 received via data
B@2 received via data
a second later
B@2 sent immediately via data
C@3 received via data
1@3 sent via buffer size
C@3 sent via data
a second later
0@3 sent via buffer size
Keywords: throttle, rate limit,
data: any
Receives data to be throttled / rate limited.
delay: number
Receives the length of the time window in milliseconds, in which to limit the number of signals. Can be set as parameter.
count: number
Receives the maximum number of signals to be forwarded in the specified time window. Can be set as parameter.
data: any
Forwards the signals received via data
, throttled.
buffer size: number
Sends the current size of the throttler's internal buffer. Only sent when the size changes. Used for raising errors related to exceeding allowed buffer size.