manager

package
v0.0.0-...-f2052c9 Latest Latest
Warning

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

Go to latest
Published: Dec 12, 2014 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RuleManager

type RuleManager interface {
	// Load and add rules from rule files specified in the configuration.
	AddRulesFromConfig(config config.Config) error
	// Start the rule manager's periodic rule evaluation.
	Run()
	// Stop the rule manager's rule evaluation cycles.
	Stop()
	// Return all rules.
	Rules() []rules.Rule
	// Return all alerting rules.
	AlertingRules() []*rules.AlertingRule
}

A RuleManager manages recording and alerting rules. Create instances with NewRuleManager.

func NewRuleManager

func NewRuleManager(o *RuleManagerOptions) RuleManager

NewRuleManager returns an implementation of RuleManager, ready to be started by calling the Run method.

type RuleManagerOptions

type RuleManagerOptions struct {
	EvaluationInterval time.Duration
	Storage            local.Storage

	NotificationHandler *notification.NotificationHandler
	Results             chan<- *extraction.Result

	PrometheusURL string
}

RuleManagerOptions bundles options for the RuleManager.

Notes

Bugs

  • Look at fixing thundering herd.

Jump to

Keyboard shortcuts

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