Documentation ¶
Index ¶
- func ExtractId(name string, prefix string, suffixLen int) (string, string)
- func MarshalJson(v interface{}) ([]byte, error)
- func NewFileEventLogger(formatterFactory LoggingHandlerFactory, stdout bool, ...) (interface{}, error)
- func NewWriterEventSink(out io.Writer) event.FormattedEventSink
- type BaseFormatter
- type Dispatcher
- func (self *Dispatcher) AcceptCircuitEvent(event *event.CircuitEvent)
- func (self *Dispatcher) AcceptLinkEvent(event *event.LinkEvent)
- func (self *Dispatcher) AcceptMetricsEvent(event *event.MetricsEvent)
- func (self *Dispatcher) AcceptMetricsMsg(msg *metrics_pb.MetricsMessage)
- func (self *Dispatcher) AcceptRouterEvent(event *event.RouterEvent)
- func (self *Dispatcher) AcceptServiceEvent(event *event.ServiceEvent)
- func (self *Dispatcher) AcceptTerminatorEvent(event *event.TerminatorEvent)
- func (self *Dispatcher) AcceptUsageEvent(event *event.UsageEvent)
- func (self *Dispatcher) AcceptUsageEventV3(event *event.UsageEventV3)
- func (self *Dispatcher) AddCircuitEventHandler(handler event.CircuitEventHandler)
- func (self *Dispatcher) AddLinkEventHandler(handler event.LinkEventHandler)
- func (self *Dispatcher) AddMetricsEventHandler(handler event.MetricsEventHandler)
- func (self *Dispatcher) AddMetricsMapper(mapper event.MetricsMapper)
- func (self *Dispatcher) AddMetricsMessageHandler(handler event.MetricsMessageHandler)
- func (self *Dispatcher) AddRouterEventHandler(handler event.RouterEventHandler)
- func (self *Dispatcher) AddServiceEventHandler(handler event.ServiceEventHandler)
- func (self *Dispatcher) AddTerminatorEventHandler(handler event.TerminatorEventHandler)
- func (self *Dispatcher) AddUsageEventHandler(handler event.UsageEventHandler)
- func (self *Dispatcher) AddUsageEventV3Handler(handler event.UsageEventV3Handler)
- func (self *Dispatcher) Dispatch(event event.Event)
- func (self *Dispatcher) GetFormatterFactory(formatType string) event.FormatterFactory
- func (self *Dispatcher) InitializeNetworkEvents(n *network.Network)
- func (self *Dispatcher) NewFilteredMetricsAdapter(sourceFilter *regexp.Regexp, metricFilter *regexp.Regexp, ...) event.MetricsMessageHandler
- func (self *Dispatcher) ProcessSubscriptions(handler interface{}, subscriptions []*event.Subscription) error
- func (self *Dispatcher) RegisterEventHandlerFactory(eventHandlerType string, factory event.HandlerFactory)
- func (self *Dispatcher) RegisterEventType(eventType string, typeRegistrar event.TypeRegistrar)
- func (self *Dispatcher) RegisterEventTypeFunctions(eventType string, registrationHandler event.RegistrationHandler, ...)
- func (self *Dispatcher) RegisterFormatterFactory(formatType string, factory event.FormatterFactory)
- func (self *Dispatcher) RemoveAllSubscriptions(handler interface{})
- func (self *Dispatcher) RemoveCircuitEventHandler(handler event.CircuitEventHandler)
- func (self *Dispatcher) RemoveLinkEventHandler(handler event.LinkEventHandler)
- func (self *Dispatcher) RemoveMetricsEventHandler(handler event.MetricsEventHandler)
- func (self *Dispatcher) RemoveMetricsMessageHandler(handler event.MetricsMessageHandler)
- func (self *Dispatcher) RemoveRouterEventHandler(handler event.RouterEventHandler)
- func (self *Dispatcher) RemoveServiceEventHandler(handler event.ServiceEventHandler)
- func (self *Dispatcher) RemoveTerminatorEventHandler(handler event.TerminatorEventHandler)
- func (self *Dispatcher) RemoveUsageEventHandler(handler event.UsageEventHandler)
- func (self *Dispatcher) RemoveUsageEventV3Handler(handler event.UsageEventV3Handler)
- func (self *Dispatcher) WireEventHandlers(eventHandlerConfigs []*EventHandlerConfig) error
- type EventHandlerConfig
- type FileEventLoggerFactory
- type FormatterEvent
- type JsonCircuitEvent
- type JsonFormatter
- func (formatter *JsonFormatter) AcceptCircuitEvent(evt *event.CircuitEvent)
- func (formatter *JsonFormatter) AcceptLinkEvent(evt *event.LinkEvent)
- func (formatter *JsonFormatter) AcceptMetricsEvent(evt *event.MetricsEvent)
- func (formatter *JsonFormatter) AcceptRouterEvent(evt *event.RouterEvent)
- func (formatter *JsonFormatter) AcceptServiceEvent(evt *event.ServiceEvent)
- func (formatter *JsonFormatter) AcceptTerminatorEvent(evt *event.TerminatorEvent)
- func (formatter *JsonFormatter) AcceptUsageEvent(evt *event.UsageEvent)
- func (formatter *JsonFormatter) AcceptUsageEventV3(evt *event.UsageEventV3)
- type JsonLinkEvent
- type JsonMetricsEvent
- type JsonRouterEvent
- type JsonServiceEvent
- type JsonTerminatorEvent
- type JsonUsageEvent
- type JsonUsageEventV3
- type LoggingHandlerFactory
- type PrometheusMetricsEvent
- type StdOutLoggerFactory
- type WriterEventSink
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MarshalJson ¶ added in v0.22.0
func NewFileEventLogger ¶ added in v0.14.9
func NewFileEventLogger(formatterFactory LoggingHandlerFactory, stdout bool, config map[interface{}]interface{}) (interface{}, error)
func NewWriterEventSink ¶ added in v0.22.0
func NewWriterEventSink(out io.Writer) event.FormattedEventSink
Types ¶
type BaseFormatter ¶ added in v0.14.9
type BaseFormatter struct {
// contains filtered or unexported fields
}
func (*BaseFormatter) AcceptLoggingEvent ¶ added in v0.14.9
func (f *BaseFormatter) AcceptLoggingEvent(event FormatterEvent)
func (*BaseFormatter) Close ¶ added in v0.22.0
func (f *BaseFormatter) Close() error
func (*BaseFormatter) Run ¶ added in v0.14.9
func (f *BaseFormatter) Run()
type Dispatcher ¶ added in v0.19.28
type Dispatcher struct {
// contains filtered or unexported fields
}
func NewDispatcher ¶ added in v0.19.28
func NewDispatcher(closeNotify <-chan struct{}) *Dispatcher
func (*Dispatcher) AcceptCircuitEvent ¶ added in v0.19.28
func (self *Dispatcher) AcceptCircuitEvent(event *event.CircuitEvent)
func (*Dispatcher) AcceptLinkEvent ¶ added in v0.19.28
func (self *Dispatcher) AcceptLinkEvent(event *event.LinkEvent)
func (*Dispatcher) AcceptMetricsEvent ¶ added in v0.19.28
func (self *Dispatcher) AcceptMetricsEvent(event *event.MetricsEvent)
func (*Dispatcher) AcceptMetricsMsg ¶ added in v0.19.28
func (self *Dispatcher) AcceptMetricsMsg(msg *metrics_pb.MetricsMessage)
func (*Dispatcher) AcceptRouterEvent ¶ added in v0.19.28
func (self *Dispatcher) AcceptRouterEvent(event *event.RouterEvent)
func (*Dispatcher) AcceptServiceEvent ¶ added in v0.19.28
func (self *Dispatcher) AcceptServiceEvent(event *event.ServiceEvent)
func (*Dispatcher) AcceptTerminatorEvent ¶ added in v0.19.28
func (self *Dispatcher) AcceptTerminatorEvent(event *event.TerminatorEvent)
func (*Dispatcher) AcceptUsageEvent ¶ added in v0.19.28
func (self *Dispatcher) AcceptUsageEvent(event *event.UsageEvent)
func (*Dispatcher) AcceptUsageEventV3 ¶ added in v0.20.0
func (self *Dispatcher) AcceptUsageEventV3(event *event.UsageEventV3)
func (*Dispatcher) AddCircuitEventHandler ¶ added in v0.19.28
func (self *Dispatcher) AddCircuitEventHandler(handler event.CircuitEventHandler)
func (*Dispatcher) AddLinkEventHandler ¶ added in v0.19.28
func (self *Dispatcher) AddLinkEventHandler(handler event.LinkEventHandler)
func (*Dispatcher) AddMetricsEventHandler ¶ added in v0.19.28
func (self *Dispatcher) AddMetricsEventHandler(handler event.MetricsEventHandler)
func (*Dispatcher) AddMetricsMapper ¶ added in v0.19.28
func (self *Dispatcher) AddMetricsMapper(mapper event.MetricsMapper)
func (*Dispatcher) AddMetricsMessageHandler ¶ added in v0.19.28
func (self *Dispatcher) AddMetricsMessageHandler(handler event.MetricsMessageHandler)
func (*Dispatcher) AddRouterEventHandler ¶ added in v0.19.28
func (self *Dispatcher) AddRouterEventHandler(handler event.RouterEventHandler)
func (*Dispatcher) AddServiceEventHandler ¶ added in v0.19.28
func (self *Dispatcher) AddServiceEventHandler(handler event.ServiceEventHandler)
func (*Dispatcher) AddTerminatorEventHandler ¶ added in v0.19.28
func (self *Dispatcher) AddTerminatorEventHandler(handler event.TerminatorEventHandler)
func (*Dispatcher) AddUsageEventHandler ¶ added in v0.19.28
func (self *Dispatcher) AddUsageEventHandler(handler event.UsageEventHandler)
func (*Dispatcher) AddUsageEventV3Handler ¶ added in v0.20.0
func (self *Dispatcher) AddUsageEventV3Handler(handler event.UsageEventV3Handler)
func (*Dispatcher) Dispatch ¶ added in v0.19.28
func (self *Dispatcher) Dispatch(event event.Event)
func (*Dispatcher) GetFormatterFactory ¶ added in v0.22.0
func (self *Dispatcher) GetFormatterFactory(formatType string) event.FormatterFactory
func (*Dispatcher) InitializeNetworkEvents ¶ added in v0.19.28
func (self *Dispatcher) InitializeNetworkEvents(n *network.Network)
func (*Dispatcher) NewFilteredMetricsAdapter ¶ added in v0.19.28
func (self *Dispatcher) NewFilteredMetricsAdapter(sourceFilter *regexp.Regexp, metricFilter *regexp.Regexp, handler event.MetricsEventHandler) event.MetricsMessageHandler
func (*Dispatcher) ProcessSubscriptions ¶ added in v0.22.0
func (self *Dispatcher) ProcessSubscriptions(handler interface{}, subscriptions []*event.Subscription) error
func (*Dispatcher) RegisterEventHandlerFactory ¶ added in v0.19.28
func (self *Dispatcher) RegisterEventHandlerFactory(eventHandlerType string, factory event.HandlerFactory)
func (*Dispatcher) RegisterEventType ¶ added in v0.19.28
func (self *Dispatcher) RegisterEventType(eventType string, typeRegistrar event.TypeRegistrar)
func (*Dispatcher) RegisterEventTypeFunctions ¶ added in v0.22.0
func (self *Dispatcher) RegisterEventTypeFunctions(eventType string, registrationHandler event.RegistrationHandler, unregistrationHandler event.UnregistrationHandler)
func (*Dispatcher) RegisterFormatterFactory ¶ added in v0.22.0
func (self *Dispatcher) RegisterFormatterFactory(formatType string, factory event.FormatterFactory)
func (*Dispatcher) RemoveAllSubscriptions ¶ added in v0.22.0
func (self *Dispatcher) RemoveAllSubscriptions(handler interface{})
func (*Dispatcher) RemoveCircuitEventHandler ¶ added in v0.19.28
func (self *Dispatcher) RemoveCircuitEventHandler(handler event.CircuitEventHandler)
func (*Dispatcher) RemoveLinkEventHandler ¶ added in v0.19.28
func (self *Dispatcher) RemoveLinkEventHandler(handler event.LinkEventHandler)
func (*Dispatcher) RemoveMetricsEventHandler ¶ added in v0.19.28
func (self *Dispatcher) RemoveMetricsEventHandler(handler event.MetricsEventHandler)
func (*Dispatcher) RemoveMetricsMessageHandler ¶ added in v0.19.28
func (self *Dispatcher) RemoveMetricsMessageHandler(handler event.MetricsMessageHandler)
func (*Dispatcher) RemoveRouterEventHandler ¶ added in v0.19.28
func (self *Dispatcher) RemoveRouterEventHandler(handler event.RouterEventHandler)
func (*Dispatcher) RemoveServiceEventHandler ¶ added in v0.19.28
func (self *Dispatcher) RemoveServiceEventHandler(handler event.ServiceEventHandler)
func (*Dispatcher) RemoveTerminatorEventHandler ¶ added in v0.19.28
func (self *Dispatcher) RemoveTerminatorEventHandler(handler event.TerminatorEventHandler)
func (*Dispatcher) RemoveUsageEventHandler ¶ added in v0.19.28
func (self *Dispatcher) RemoveUsageEventHandler(handler event.UsageEventHandler)
func (*Dispatcher) RemoveUsageEventV3Handler ¶ added in v0.20.0
func (self *Dispatcher) RemoveUsageEventV3Handler(handler event.UsageEventV3Handler)
func (*Dispatcher) WireEventHandlers ¶ added in v0.19.28
func (self *Dispatcher) WireEventHandlers(eventHandlerConfigs []*EventHandlerConfig) error
WireEventHandlers takes the given handler configs and creates handlers and subscriptions for each of them. * Example configuration: events:
jsonLogger: subscriptions: - type: metrics sourceFilter: .* metricFilter: .*xgress.*tx*.m1_rate - type: fabric.circuits include: - created - type: edge.sessions include: - created handler: type: file format: json path: /tmp/ziti-events.log
type EventHandlerConfig ¶ added in v0.19.28
type EventHandlerConfig struct { Id interface{} Config map[interface{}]interface{} }
type FileEventLoggerFactory ¶ added in v0.14.9
type FileEventLoggerFactory struct{}
func (FileEventLoggerFactory) NewEventHandler ¶ added in v0.14.9
func (FileEventLoggerFactory) NewEventHandler(config map[interface{}]interface{}) (interface{}, error)
type FormatterEvent ¶ added in v0.22.0
type JsonCircuitEvent ¶ added in v0.19.28
type JsonCircuitEvent event.CircuitEvent
func (*JsonCircuitEvent) Format ¶ added in v0.22.0
func (event *JsonCircuitEvent) Format() ([]byte, error)
func (*JsonCircuitEvent) GetEventType ¶ added in v0.22.0
func (event *JsonCircuitEvent) GetEventType() string
type JsonFormatter ¶ added in v0.14.9
type JsonFormatter struct {
BaseFormatter
}
func NewJsonFormatter ¶ added in v0.14.9
func NewJsonFormatter(queueDepth int, sink event.FormattedEventSink) *JsonFormatter
func (*JsonFormatter) AcceptCircuitEvent ¶ added in v0.16.92
func (formatter *JsonFormatter) AcceptCircuitEvent(evt *event.CircuitEvent)
func (*JsonFormatter) AcceptLinkEvent ¶ added in v0.19.28
func (formatter *JsonFormatter) AcceptLinkEvent(evt *event.LinkEvent)
func (*JsonFormatter) AcceptMetricsEvent ¶ added in v0.14.9
func (formatter *JsonFormatter) AcceptMetricsEvent(evt *event.MetricsEvent)
func (*JsonFormatter) AcceptRouterEvent ¶ added in v0.16.56
func (formatter *JsonFormatter) AcceptRouterEvent(evt *event.RouterEvent)
func (*JsonFormatter) AcceptServiceEvent ¶ added in v0.16.23
func (formatter *JsonFormatter) AcceptServiceEvent(evt *event.ServiceEvent)
func (*JsonFormatter) AcceptTerminatorEvent ¶ added in v0.15.6
func (formatter *JsonFormatter) AcceptTerminatorEvent(evt *event.TerminatorEvent)
func (*JsonFormatter) AcceptUsageEvent ¶ added in v0.14.9
func (formatter *JsonFormatter) AcceptUsageEvent(evt *event.UsageEvent)
func (*JsonFormatter) AcceptUsageEventV3 ¶ added in v0.20.0
func (formatter *JsonFormatter) AcceptUsageEventV3(evt *event.UsageEventV3)
type JsonLinkEvent ¶ added in v0.19.28
func (*JsonLinkEvent) Format ¶ added in v0.22.0
func (event *JsonLinkEvent) Format() ([]byte, error)
func (*JsonLinkEvent) GetEventType ¶ added in v0.22.0
func (event *JsonLinkEvent) GetEventType() string
type JsonMetricsEvent ¶ added in v0.14.9
type JsonMetricsEvent event.MetricsEvent
func (*JsonMetricsEvent) Format ¶ added in v0.22.0
func (event *JsonMetricsEvent) Format() ([]byte, error)
func (*JsonMetricsEvent) GetEventType ¶ added in v0.22.0
func (event *JsonMetricsEvent) GetEventType() string
type JsonRouterEvent ¶ added in v0.16.56
type JsonRouterEvent event.RouterEvent
func (*JsonRouterEvent) Format ¶ added in v0.22.0
func (event *JsonRouterEvent) Format() ([]byte, error)
func (*JsonRouterEvent) GetEventType ¶ added in v0.22.0
func (event *JsonRouterEvent) GetEventType() string
type JsonServiceEvent ¶ added in v0.16.23
type JsonServiceEvent event.ServiceEvent
func (*JsonServiceEvent) Format ¶ added in v0.22.0
func (event *JsonServiceEvent) Format() ([]byte, error)
func (*JsonServiceEvent) GetEventType ¶ added in v0.22.0
func (event *JsonServiceEvent) GetEventType() string
type JsonTerminatorEvent ¶ added in v0.15.6
type JsonTerminatorEvent event.TerminatorEvent
func (*JsonTerminatorEvent) Format ¶ added in v0.22.0
func (event *JsonTerminatorEvent) Format() ([]byte, error)
func (*JsonTerminatorEvent) GetEventType ¶ added in v0.22.0
func (event *JsonTerminatorEvent) GetEventType() string
type JsonUsageEvent ¶ added in v0.14.9
type JsonUsageEvent event.UsageEvent
func (*JsonUsageEvent) Format ¶ added in v0.22.0
func (event *JsonUsageEvent) Format() ([]byte, error)
func (*JsonUsageEvent) GetEventType ¶ added in v0.22.0
func (event *JsonUsageEvent) GetEventType() string
type JsonUsageEventV3 ¶ added in v0.20.0
type JsonUsageEventV3 event.UsageEventV3
func (*JsonUsageEventV3) Format ¶ added in v0.22.0
func (event *JsonUsageEventV3) Format() ([]byte, error)
func (*JsonUsageEventV3) GetEventType ¶ added in v0.22.0
func (event *JsonUsageEventV3) GetEventType() string
type LoggingHandlerFactory ¶ added in v0.14.9
type LoggingHandlerFactory interface {
NewLoggingHandler(format string, buffer int, out io.WriteCloser) (interface{}, error)
}
type PrometheusMetricsEvent ¶ added in v0.17.142
type PrometheusMetricsEvent event.MetricsEvent
func (*PrometheusMetricsEvent) Marshal ¶ added in v0.17.142
func (event *PrometheusMetricsEvent) Marshal(includeTimestamps bool) ([]byte, error)
func (*PrometheusMetricsEvent) WriteTo ¶ added in v0.17.142
func (event *PrometheusMetricsEvent) WriteTo(output io.WriteCloser, includeTimestamps bool) error
type StdOutLoggerFactory ¶ added in v0.14.9
type StdOutLoggerFactory struct{}
func (StdOutLoggerFactory) NewEventHandler ¶ added in v0.14.9
func (StdOutLoggerFactory) NewEventHandler(config map[interface{}]interface{}) (interface{}, error)
type WriterEventSink ¶ added in v0.22.0
type WriterEventSink struct {
// contains filtered or unexported fields
}
func (WriterEventSink) AcceptFormattedEvent ¶ added in v0.22.0
func (self WriterEventSink) AcceptFormattedEvent(_ string, formattedEvent []byte)
Click to show internal directories.
Click to hide internal directories.