alertmanager

package
v2.11.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Oct 14, 2020 License: AGPL-3.0 Imports: 13 Imported by: 0

Documentation

Overview

Package alertmanager contains business logic of working with Alertmanager.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Service

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

Service is responsible for interactions with Alertmanager.

func New

func New(db *reform.DB) *Service

New creates new service.

func (*Service) IsReady

func (svc *Service) IsReady(ctx context.Context) error

IsReady verifies that Alertmanager works.

func (*Service) Run

func (svc *Service) Run(ctx context.Context)

Run runs Alertmanager configuration update loop until ctx is canceled.

func (*Service) SendAlerts

func (svc *Service) SendAlerts(ctx context.Context, alerts ammodels.PostableAlerts)

SendAlerts sends given alerts. It is the caller's responsibility to call this method every now and then.

Jump to

Keyboard shortcuts

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