Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Throttler ¶
type Throttler struct {
// contains filtered or unexported fields
}
func New ¶
New creates a new instance of throttler. maxDelay controls what min time interval between consecutive operations is allowed at the top throttling level.
func (*Throttler) Adjust ¶
Adjust controls the throttling level depending on a result of some task execution. It throttles UP if the task is done successfully (done=true) or throttles DOWN otherwise (done=false).
Click to show internal directories.
Click to hide internal directories.