Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Batcher ¶
type Batcher[T any] struct { Buffer int `mapstructure:"batch_buffer"` Interval time.Duration `mapstructure:"batch_interval"` }
batcher is a helper for cases when plugin needs to send events in batches it passes a batch of events to passed func when: - buffer is full - ticker ticks - input chanel is closed and readed to the end
batcher clears buffer after each call of flushFn()
Click to show internal directories.
Click to hide internal directories.