cortex

package
v3.0.0-...-d6c4d9c Latest Latest
Warning

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

Go to latest
Published: Apr 14, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	GetAlertmanagerConfiguration(ctx context.Context, tenant string) ([]byte, error)
	SetAlertmanagerConfiguration(ctx context.Context, tenant string, config []byte) error
	DeleteAlertmanagerConfiguration(ctx context.Context, tenant string) error

	GetRuleGroupConfiguration(ctx context.Context, tenant string, ruleGroupType kubermaticv1.RuleGroupType, groupName string) ([]byte, error)
	SetRuleGroupConfiguration(ctx context.Context, tenant string, ruleGroupType kubermaticv1.RuleGroupType, groupName string, config []byte) error
	DeleteRuleGroupConfiguration(ctx context.Context, tenant string, ruleGroupType kubermaticv1.RuleGroupType, groupName string) error
}

func NewClient

func NewClient(httpClient *http.Client, alertmanagerURL string, rulerURL string, lokiURL string) Client

type ClientProvider

type ClientProvider func() Client

type FakeCortex

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

func NewFakeClient

func NewFakeClient() *FakeCortex

func (*FakeCortex) DeleteAlertmanagerConfiguration

func (c *FakeCortex) DeleteAlertmanagerConfiguration(ctx context.Context, tenant string) error

func (*FakeCortex) DeleteRuleGroupConfiguration

func (c *FakeCortex) DeleteRuleGroupConfiguration(ctx context.Context, tenant string, ruleGroupType kubermaticv1.RuleGroupType, groupName string) error

func (*FakeCortex) GetAlertmanagerConfiguration

func (c *FakeCortex) GetAlertmanagerConfiguration(ctx context.Context, tenant string) ([]byte, error)

func (*FakeCortex) GetRuleGroupConfiguration

func (c *FakeCortex) GetRuleGroupConfiguration(ctx context.Context, tenant string, ruleGroupType kubermaticv1.RuleGroupType, groupName string) ([]byte, error)

func (*FakeCortex) SetAlertmanagerConfiguration

func (c *FakeCortex) SetAlertmanagerConfiguration(ctx context.Context, tenant string, config []byte) error

func (*FakeCortex) SetRuleGroupConfiguration

func (c *FakeCortex) SetRuleGroupConfiguration(ctx context.Context, tenant string, ruleGroupType kubermaticv1.RuleGroupType, groupName string, config []byte) error

Jump to

Keyboard shortcuts

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