Documentation ¶
Overview ¶
API package with type definitions
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BatchTrigger ¶
BatchTrigger interface provides logic to trigger when batch is done.
type BatchTriggerFunc ¶
BatchTriggerFunc a function type adapter that implements BatchTrigger
type BinFunc ¶
BinFunc implements BinOperation as type func(context.Context, interface{}, interface{})
type BinOperation ¶
BinOperation interface represents binary opeartions (i.e. Reduce, etc)
type CancelStreamError ¶
type CancelStreamError StreamError
CancelStreamError signals that all stream activities should stop and the streaming should gracefully end
func CancellationError ¶
func CancellationError(msg string) CancelStreamError
CancellationError returns a CancelStreamError
func (CancelStreamError) Error ¶
func (e CancelStreamError) Error() string
type ErrorFunc ¶
type ErrorFunc func(StreamError)
ErrorFunc this type is a user-provided function to handle errors
type PanicStreamError ¶
type PanicStreamError StreamError
PanicStreamError signals that the stream should panic immediately
func PanickingError ¶
func PanickingError(msg string) PanicStreamError
PanickingError returns a PanicStreamError
func (PanicStreamError) Error ¶
func (e PanicStreamError) Error() string
type StreamError ¶
type StreamError struct {
// contains filtered or unexported fields
}
StreamError is used to signal runtime stream error
func ErrorWithItem ¶
func ErrorWithItem(msg string, item *StreamItem) StreamError
ErrorWithItem returns a StreamError with provided StreamItem
func (StreamError) Error ¶
func (e StreamError) Error() string
func (StreamError) Item ¶
func (e StreamError) Item() *StreamItem
Item returns the StreamItem associated with the error
type StreamItem ¶
type StreamItem struct { Index int64 // index of the item in the stream Item interface{} // data item being stream MetaData map[string]string // user-provided stream metadat Context context.Context // stream context }
StreamItem can be used to provide a rich repressentation of streaming data. Stream data can be wrapped in StreamItem carry additional information downstream including context, metadata, and error.
type UnOperation ¶
UnOperation interface represents unary operations (i.e. Map, Filter, etc)