Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type RouterOperator ¶
type RouterOperator struct { helper.BasicOperator // contains filtered or unexported fields }
RouterOperator is an operator that routes entries based on matching expressions
func (*RouterOperator) CanOutput ¶
func (p *RouterOperator) CanOutput() bool
CanOutput will always return true for a router operator
func (*RouterOperator) CanProcess ¶
func (p *RouterOperator) CanProcess() bool
CanProcess will always return true for a router operator
func (*RouterOperator) Outputs ¶
func (p *RouterOperator) Outputs() []operator.Operator
Outputs will return all connected operators.
func (*RouterOperator) SetOutputs ¶
func (p *RouterOperator) SetOutputs(operators []operator.Operator) error
SetOutputs will set the outputs of the router operator.
type RouterOperatorConfig ¶
type RouterOperatorConfig struct { helper.BasicConfig `yaml:",inline"` Routes []*RouterOperatorRouteConfig `json:"routes" yaml:"routes"` }
RouterOperatorConfig is the configuration of a router operator
func NewRouterOperatorConfig ¶
func NewRouterOperatorConfig(operatorID string) *RouterOperatorConfig
NewRouterOperatorConfig config creates a new router operator config with default values
func (RouterOperatorConfig) Build ¶
func (c RouterOperatorConfig) Build(bc operator.BuildContext) (operator.Operator, error)
Build will build a router operator from the supplied configuration
type RouterOperatorRoute ¶
type RouterOperatorRoute struct { helper.Labeler Expression *vm.Program OutputIDs helper.OutputIDs OutputOperators []operator.Operator }
RouterOperatorRoute is a route on a router operator
type RouterOperatorRouteConfig ¶
type RouterOperatorRouteConfig struct { helper.LabelerConfig `yaml:",inline"` Expression string `json:"expr" yaml:"expr"` OutputIDs helper.OutputIDs `json:"output" yaml:"output"` }
RouterOperatorRouteConfig is the configuration of a route on a router operator