Documentation ¶
Overview ¶
Package alertsilence defines AlertSilence object definitions.
Index ¶
- type AlertPolicySource
- type AlertSilence
- func (a AlertSilence) GetKind() manifest.Kind
- func (a AlertSilence) GetManifestSource() string
- func (a AlertSilence) GetName() string
- func (a AlertSilence) GetOrganization() string
- func (a AlertSilence) GetProject() string
- func (a AlertSilence) GetValidator() govy.Validator[AlertSilence]
- func (a AlertSilence) GetVersion() manifest.Version
- func (a AlertSilence) SetManifestSource(src string) manifest.Object
- func (a AlertSilence) SetOrganization(org string) manifest.Object
- func (a AlertSilence) SetProject(project string) manifest.Object
- func (a AlertSilence) Validate() error
- type Metadata
- type Period
- type Spec
- type Status
Examples ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AlertPolicySource ¶
type AlertPolicySource struct { Name string `json:"name"` Project string `json:"project,omitempty"` }
AlertPolicySource represents AlertPolicy attached to the SLO.
type AlertSilence ¶
type AlertSilence struct { APIVersion manifest.Version `json:"apiVersion"` Kind manifest.Kind `json:"kind"` Metadata Metadata `json:"metadata"` Spec Spec `json:"spec"` Status *Status `json:"status,omitempty"` Organization string `json:"organization,omitempty"` ManifestSource string `json:"manifestSrc,omitempty"` }
AlertSilence represents alerts silencing configuration for given SLO and AlertPolicy.
Example ¶
Output: apiVersion: n9/v1alpha kind: AlertSilence metadata: name: my-alert-silence project: default spec: description: Example alert silence slo: my-slo alertPolicy: name: my-alert-policy project: default period: startTime: 2023-05-01T17:10:05Z duration: 10m
func New ¶
func New(metadata Metadata, spec Spec) AlertSilence
New creates a new AlertSilence based on provided Metadata nad Spec.
func (AlertSilence) GetKind ¶
func (a AlertSilence) GetKind() manifest.Kind
func (AlertSilence) GetManifestSource ¶
func (a AlertSilence) GetManifestSource() string
func (AlertSilence) GetName ¶
func (a AlertSilence) GetName() string
func (AlertSilence) GetOrganization ¶
func (a AlertSilence) GetOrganization() string
func (AlertSilence) GetProject ¶
func (a AlertSilence) GetProject() string
func (AlertSilence) GetValidator ¶ added in v0.82.0
func (a AlertSilence) GetValidator() govy.Validator[AlertSilence]
func (AlertSilence) GetVersion ¶
func (a AlertSilence) GetVersion() manifest.Version
func (AlertSilence) SetManifestSource ¶
func (a AlertSilence) SetManifestSource(src string) manifest.Object
func (AlertSilence) SetOrganization ¶
func (a AlertSilence) SetOrganization(org string) manifest.Object
func (AlertSilence) SetProject ¶
func (a AlertSilence) SetProject(project string) manifest.Object
func (AlertSilence) Validate ¶
func (a AlertSilence) Validate() error
type Metadata ¶
Metadata defines only basic metadata fields - name and project which uniquely identifies object on project level.
type Period ¶
type Period struct { StartTime *time.Time `json:"startTime,omitempty"` EndTime *time.Time `json:"endTime,omitempty"` Duration string `json:"duration,omitempty"` }
Period represents time range configuration for AlertSilence.
Click to show internal directories.
Click to hide internal directories.