alerting

package
v1.0.13 Latest Latest
Warning

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

Go to latest
Published: Mar 16, 2026 License: MPL-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AlertEvent

type AlertEvent struct {
	Name      string    `json:"name"`
	Trigger   string    `json:"trigger"`
	Channel   string    `json:"channel"`
	Value     int64     `json:"value"`
	Threshold int       `json:"threshold"`
	Timestamp time.Time `json:"timestamp"`
	Message   string    `json:"message"`
}

type AlertManager

type AlertManager struct {
	// contains filtered or unexported fields
}

func NewAlertManager

func NewAlertManager(alerts []config.AlertConfig, metrics *observability.Metrics, send AlertSendFunc, logger *slog.Logger) *AlertManager

func (*AlertManager) Start

func (am *AlertManager) Start(ctx context.Context)

func (*AlertManager) Stop

func (am *AlertManager) Stop()

type AlertSendFunc

type AlertSendFunc func(ctx context.Context, destination string, payload []byte) error

Jump to

Keyboard shortcuts

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