Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FanOut ¶
type FanOut[I, O any] struct { // contains filtered or unexported fields }
func (*FanOut[I, O]) Process ¶
func (f *FanOut[I, O]) Process(p ProcessorFunc[I])
type HashedFanOut ¶
HashedFanOut is a special purpose fan out that hashes the input so that the same keys are always processed by the same worker. This is used to ensure guard against race conditions in non-reentrant processors.
func NewHashedFanOut ¶
func NewHashedFanOut[I, O any](workerCount, bufferSize int, hasher HashFunc[I]) *HashedFanOut[I, O]
func (*HashedFanOut[I, O]) Close ¶
func (f *HashedFanOut[I, O]) Close()
func (*HashedFanOut[I, O]) Invoke ¶
func (f *HashedFanOut[I, O]) Invoke(input I)
func (*HashedFanOut[I, O]) Process ¶
func (f *HashedFanOut[I, O]) Process(p ProcessorFunc[I])
type ProcessorFunc ¶
type ProcessorFunc[I any] func(I)
Click to show internal directories.
Click to hide internal directories.