Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ManagerData ¶
type ManagerData struct {
Data Manager `json:"data"`
}
type Rule ¶
type RuleGroup ¶
type RuleGroup struct { Name string `json:"name"` Interval Duration `json:"interval,omitempty"` Rules []Rule `json:"rules"` }
func (*RuleGroup) ConvertToPromRuleGroup ¶
type RuleGroupData ¶
type RuleGroupData struct {
Data RuleGroup `json:"data"`
}
type RulesClient ¶
type RulesClient struct {
// contains filtered or unexported fields
}
func NewRulesClient ¶
func NewRulesClient(addr string, tlsConfig *tls.Config, opts ...RulesClientOption) *RulesClient
func (*RulesClient) CreateManager ¶
func (c *RulesClient) CreateManager(managerId, alertmanagerAddr string) (*Manager, *ApiError)
func (*RulesClient) DeleteManager ¶
func (c *RulesClient) DeleteManager(managerId string) *ApiError
func (*RulesClient) UpsertRuleGroup ¶
func (c *RulesClient) UpsertRuleGroup(managerId string, ruleGroup RuleGroup) (*RuleGroup, *ApiError)
type RulesClientOption ¶
type RulesClientOption func(*RulesClient)
func WithRulesClientLogger ¶
func WithRulesClientLogger(log *logger.Logger) RulesClientOption
func WithRulesClientPrivate ¶
func WithRulesClientPrivate() RulesClientOption
func WithRulesClientTimeout ¶
func WithRulesClientTimeout(timeout time.Duration) RulesClientOption
Click to show internal directories.
Click to hide internal directories.