package
0.0.0-20240923235104-a1285cd89b11
Repository: https://github.com/hedisam/pipeline.git
Documentation: pkg.go.dev
# Functions
Broadcast returns a Runner that supports the 1-to-N broadcasting pattern which allows us to concurrently process each incoming payload by N different processors.
DynamicWorkerPoolRunner returns a worker pool stage runner with dynamic workers.
FIFORunner returns a Runner that processes input data sequentially, thereby maintaining their order.
IsEOFSignal checks if a message received by a processor is the EOF signal message.
NewTokenPool returns an instance of TokenPool with the specified pool cap.
WithEOFMessage configures the Runner to send an EOF message to the processor when the input channel is closed.
WithMaxConcurrentBroadcasts controls how many messages to be sent concurrently by the Broadcast stage runner.
WorkerPoolRunner creates and returns a fixed size worker pool stage Runner.
# Type aliases
Option defines a function that can be used to customise the Config.
Processor is a function that process an input payload and outputs the processed data.
Runner takes a stage index and an input channel; and returns two read-only channels, one for processed payloads and one for errors, respectively.