Documentation ¶
Index ¶
- Constants
- Variables
- func ReceiverFeatures(c *config.DataSet) map[string]interface{}
- func StartEngine(cfg *config.Config)
- func StartOperator(cfg *config.Config)
- func StartReceiver(cfg *config.Config)
- type CollapsedRule
- type ExpectHandler
- type MessageResponder
- type RoutedMessage
- type Service
- type WorkflowHelper
Constants ¶
const (
FeatureEmitter = "emitter"
)
features known to the service for providing some functionalities
Variables ¶
var Services = map[string]*Service{}
Services holds a catalog of running services in this daemon process.
Functions ¶
func ReceiverFeatures ¶
ReceiverFeatures goes through the config data to figure out what driver/feature to start for receiving events
func StartOperator ¶
StartOperator starts the operator service
func StartReceiver ¶
StartReceiver starts the receiver service.
Types ¶
type CollapsedRule ¶
type CollapsedRule struct { Trigger *config.CollapsedTrigger OriginalRule *config.Rule }
CollapsedRule maps the rule to its all collapsed match and exports.
type ExpectHandler ¶
ExpectHandler is a function type that handles expected message.
type MessageResponder ¶
MessageResponder is a function type that respond to messages.
type RoutedMessage ¶
type RoutedMessage struct {
// contains filtered or unexported fields
}
RoutedMessage stores a dipper message and its destination.
type Service ¶
type Service struct { dipper.RPCCaller Route func(*dipper.Message) []RoutedMessage DiscoverFeatures func(*config.DataSet) map[string]interface{} ServiceReload func(*config.Config) EmitMetrics func() // contains filtered or unexported fields }
Service is a collection of daemon's feature.
func NewService ¶
NewService creates a service with given config and name.
func (*Service) CounterIncr ¶
CounterIncr increases a counter metric.
type WorkflowHelper ¶ added in v1.0.0
type WorkflowHelper struct {
// contains filtered or unexported fields
}
WorkflowHelper enables workflow engine to load config and send messages
func (*WorkflowHelper) GetConfig ¶ added in v1.0.0
func (h *WorkflowHelper) GetConfig() *config.Config
GetConfig method feed config from service to workflow engine
func (*WorkflowHelper) SendMessage ¶ added in v1.0.0
func (h *WorkflowHelper) SendMessage(msg *dipper.Message)
SendMessage method sends workflow messages to eventbus channle