Documentation
¶
Index ¶
- Constants
- func NewApplier(pctx *Context, parent zbuf.Puller, apply expr.Applier) *applier
- func NopDone(puller zbuf.Puller) *done
- func Unwrap(batch zbuf.Batch) (zbuf.Batch, int)
- type Catcher
- type Context
- type DataAdaptor
- type EndOfChannel
- type Mux
- type Result
- type Router
- type Scheduler
- type Selector
- type Single
Constants ¶
const BatchLen = 100
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Catcher ¶
type Catcher struct {
// contains filtered or unexported fields
}
Catcher wraps an Interface with a Pull method that recovers panics and turns them into errors. It should be wrapped around the output puller of a flowgraph and the top-level puller of any goroutine created inside of a flowgraph.
func NewCatcher ¶
type Context ¶
type Context struct {
context.Context
Logger *zap.Logger
Zctx *zed.Context
// contains filtered or unexported fields
}
Context provides states used by all procs to provide the outside context in which they are running.
func DefaultContext ¶
func DefaultContext() *Context
func NewContext ¶
type DataAdaptor ¶
type DataAdaptor interface {
PoolID(context.Context, string) (ksuid.KSUID, error)
CommitObject(context.Context, ksuid.KSUID, string) (ksuid.KSUID, error)
Layout(context.Context, dag.Source) order.Layout
NewScheduler(context.Context, *zed.Context, dag.Source, extent.Span, zbuf.Filter, *dag.Filter) (Scheduler, error)
Open(context.Context, *zed.Context, string, zbuf.Filter) (zbuf.PullerCloser, error)
}
type EndOfChannel ¶
type EndOfChannel int
EndOfChannel is an empty batch that represents the termination of one of the output paths of a muxed flowgraph and thus will be ignored downstream unless explicitly detected.
func (*EndOfChannel) Ref ¶
func (*EndOfChannel) Ref()
func (*EndOfChannel) Unref ¶
func (*EndOfChannel) Unref()
func (*EndOfChannel) Values ¶
func (*EndOfChannel) Values() []zed.Value
func (*EndOfChannel) Vars ¶
func (*EndOfChannel) Vars() []zed.Value
type Mux ¶
type Mux struct {
// contains filtered or unexported fields
}
Mux implements the muxing of a set of parallel paths at the output of a flowgraph. It also implements the double-EOS algorithm with proc.Latch to detect the end of each parallel stream. Its output protocol is a single EOS when all of the upstream legs are done at which time it cancels the flowgraoh. Each batch returned by the mux is wrapped in a Batch, which can be unwrappd with Unwrap to extract the integer index of the output (in left-to-right DFS traversal order of the flowgraph). This proc requires more than one parent; use proc.Latcher for a single-output flowgraph.