axe

package
v0.0.0-...-9b5cd94 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 5, 2024 License: AGPL-3.0 Imports: 50 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewEngine

func NewEngine(
	ctx context.Context,
	options Options,
	dbClient mongo.DbClient,
	amqpConnection amqp.Connection,
	cfg config.CanopsisConf,
	metricsSender metrics.Sender,
	autoInstructionMatcher event.AutoInstructionMatcher,
	remediationRpcClient libengine.RPCClient,
	dynamicInfosRpcClient libengine.RPCClient,
	rpcPublishQueues []string,
	logger zerolog.Logger,
) libengine.Engine

func NewMetaAlarmEventProcessor

func NewMetaAlarmEventProcessor(
	dbClient mongo.DbClient,
	adapter libalarm.Adapter,
	ruleAdapter correlation.RulesAdapter,
	alarmStatusService alarmstatus.Service,
	alarmConfigProvider config.AlarmConfigProvider,
	encoder encoding.Encoder,
	amqpPublisher libamqp.Publisher,
	metricsSender metrics.Sender,
	metaAlarmStatesService correlation.MetaAlarmStateService,
	templateExecutor template.Executor,
	logger zerolog.Logger,
) libalarm.MetaAlarmEventProcessor

Types

type DependencyMaker

type DependencyMaker struct {
	depmake.DependencyMaker
}

func (DependencyMaker) EventProcessor

func (m DependencyMaker) EventProcessor(
	dbClient mongo.DbClient,
	alarmConfigProvider config.AlarmConfigProvider,
	userInterfaceConfigProvider config.UserInterfaceConfigProvider,
	alarmStatusService alarmstatus.Service,
	pbhTypeResolver pbehavior.EntityTypeResolver,
	autoInstructionMatcher event.AutoInstructionMatcher,
	entityServiceCountersCalculator calculator.EntityServiceCountersCalculator,
	componentCountersCalculator calculator.ComponentCountersCalculator,
	eventsSender entitycounters.EventsSender,
	metaAlarmEventProcessor libalarm.MetaAlarmEventProcessor,
	metricsSender metrics.Sender,
	eventStatisticsSender statistics.EventStatisticsSender,
	remediationRpcClient libengine.RPCClient,
	externalTagUpdater alarmtag.ExternalUpdater,
	internalTagAlarmMatcher alarmtag.InternalTagAlarmMatcher,
	amqpPublisher amqp.Publisher,
	logger zerolog.Logger,
) event.Processor

type MessageProcessor

type MessageProcessor struct {
	FeaturePrintEventOnError bool

	EventProcessor    libevent.Processor
	Encoder           encoding.Encoder
	Decoder           encoding.Decoder
	TechMetricsSender techmetrics.Sender
	AlarmCollection   mongo.DbCollection
	Logger            zerolog.Logger
}

func (*MessageProcessor) Process

func (p *MessageProcessor) Process(parentCtx context.Context, d amqp.Delivery) ([]byte, error)

type Options

type Options struct {
	Version                  bool
	FeaturePrintEventOnError bool
	ModeDebug                bool
	PublishToQueue           string
	FifoAckExchange          string
	PeriodicalWaitTime       time.Duration
	TagsPeriodicalWaitTime   time.Duration
	SliPeriodicalWaitTime    time.Duration
	RecomputeAllOnInit       bool
	Workers                  int
}

func ParseOptions

func ParseOptions() Options

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL