notify

package
v0.0.0-...-1a3a2fa Latest Latest
Warning

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

Go to latest
Published: Jun 11, 2026 License: BSD-3-Clause Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(cfg config.Notify, baseURL *url.URL, pushSvc NotifierBackend) (*notifier, error)

Types

type Notifier

type Notifier interface {
	Send(ctx context.Context, alerts []alert.Alert) error
}

A Notiifer is the notification controller.

type NotifierBackend

type NotifierBackend interface {
	// Dispatch sends the rendered alerts out to recipients.
	DispatchAlerts(ctx context.Context, renderedAlerts *alert.RenderedAlertBatch) error
}

A NotifierBackend actually dispatches the notiication to the recipients.

func NewSlackWebhookBackend

func NewSlackWebhookBackend(cfg config.ConfigMap) (NotifierBackend, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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