Documentation ¶
Overview ¶
Copyright © 2022 NAME HERE <EMAIL ADDRESS>
Copyright © 2022 NAME HERE <EMAIL ADDRESS>
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Execute ¶
func Execute()
Execute adds all child commands to the root command and sets flags appropriately. This is called by main.main(). It only needs to happen once to the rootCmd.
func WaitSignals ¶
Types ¶
type DynamicProbeServer ¶ added in v1.0.0
func NewDynamicProbeServer ¶ added in v1.0.0
func NewDynamicProbeServer[T probe.Probe](probeManager ProbeManager[T]) *DynamicProbeServer[T]
func (*DynamicProbeServer[T]) Reload ¶ added in v1.0.0
func (s *DynamicProbeServer[T]) Reload(ctx context.Context, config []ProbeConfig) error
func (*DynamicProbeServer[T]) Start ¶ added in v1.0.0
func (s *DynamicProbeServer[T]) Start(ctx context.Context, config []ProbeConfig) error
type EventConfig ¶
type EventConfig struct { EventSinks []EventSinkConfig `yaml:"sinks" mapstructure:"sinks" json:"sinks"` Probes []ProbeConfig `yaml:"probes" mapstructure:"probes" json:"probes"` }
type EventProbeManager ¶ added in v1.0.0
type EventProbeManager struct {
// contains filtered or unexported fields
}
func (*EventProbeManager) CreateProbe ¶ added in v1.0.0
func (m *EventProbeManager) CreateProbe(config ProbeConfig) (probe.EventProbe, error)
func (*EventProbeManager) StartProbe ¶ added in v1.0.0
func (m *EventProbeManager) StartProbe(ctx context.Context, probe probe.EventProbe) error
func (*EventProbeManager) StopProbe ¶ added in v1.0.0
func (m *EventProbeManager) StopProbe(ctx context.Context, probe probe.EventProbe) error
type EventServer ¶ added in v1.0.0
type EventServer struct { *DynamicProbeServer[probe.EventProbe] }
func NewEventServer ¶ added in v1.0.0
func NewEventServer(sinks []sink.Sink) (*EventServer, error)
func (*EventServer) Start ¶ added in v1.0.0
func (s *EventServer) Start(ctx context.Context, probeConfig []ProbeConfig) error
type EventSinkConfig ¶ added in v1.0.0
type EventSinkConfig struct { Name string `yaml:"name" mapstructure:"name" json:"name"` Args interface{} `yaml:"args" mapstructure:"args" json:"args"` }
type InspServerConfig ¶ added in v1.0.0
type InspServerConfig struct { DebugMode bool `yaml:"debugmode" mapstructure:"debugmode" json:"debugmode"` Port uint16 `yaml:"port" mapstructure:"port" json:"port"` EnableController bool `yaml:"enable_controller" mapstructure:"enable_controller" json:"enable_controller"` MetricsConfig MetricsConfig `yaml:"metrics" mapstructure:"metrics" json:"metrics"` EventConfig EventConfig `yaml:"event" mapstructure:"event" json:"event"` }
type MetricsConfig ¶ added in v1.0.0
type MetricsConfig struct {
Probes []ProbeConfig `yaml:"probes" mapstructure:"probes" json:"probes"`
}
type MetricsProbeManager ¶ added in v1.0.0
type MetricsProbeManager struct {
// contains filtered or unexported fields
}
func (*MetricsProbeManager) CreateProbe ¶ added in v1.0.0
func (m *MetricsProbeManager) CreateProbe(config ProbeConfig) (probe.MetricsProbe, error)
func (*MetricsProbeManager) StartProbe ¶ added in v1.0.0
func (m *MetricsProbeManager) StartProbe(ctx context.Context, probe probe.MetricsProbe) error
func (*MetricsProbeManager) StopProbe ¶ added in v1.0.0
func (m *MetricsProbeManager) StopProbe(ctx context.Context, probe probe.MetricsProbe) error
type MetricsServer ¶ added in v1.0.0
type MetricsServer struct { *DynamicProbeServer[probe.MetricsProbe] // contains filtered or unexported fields }
func NewMetricsServer ¶ added in v1.0.0
func NewMetricsServer() (*MetricsServer, error)
func (*MetricsServer) ServeHTTP ¶ added in v1.0.0
func (s *MetricsServer) ServeHTTP(w http.ResponseWriter, r *http.Request)
type ProbeConfig ¶ added in v1.0.0
Click to show internal directories.
Click to hide internal directories.