Documentation ¶
Overview ¶
Package v1alpha1 contains API Schema definitions for the monitoring v1alpha1 API group +kubebuilder:object:generate=true +groupName=monitoring.kanzifucius.com
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ( // GroupVersion is group version used to register these objects GroupVersion = schema.GroupVersion{Group: "monitoring.kanzifucius.com", Version: "v1alpha1"} // SchemeBuilder is used to add go types to the GroupVersionKind scheme SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion} // AddToScheme adds the types in this group-version to the given scheme. AddToScheme = SchemeBuilder.AddToScheme )
var ( DefaultSamples = []sample{ { Name: "short", Interval: "30s", Buckets: []string{"5m", "30m", "1h"}, }, { Name: "medium", Interval: "2m", Buckets: []string{"2h", "6h"}, }, { Name: "daily", Interval: "5m", Buckets: []string{"1d", "3d"}, }, } )
Functions ¶
This section is empty.
Types ¶
type ExprBlock ¶
type ExprBlock struct { // +kubebuilder:validation:Optional AlertMethod string `json:"alertMethod"` // +kubebuilder:validation:Optional BurnRate string `json:"burnRate"` // +kubebuilder:validation:Optional Windows []Window `json:"windows"` // +kubebuilder:validation:Optional ShortWindow *bool `json:"shortWindow"` // +kubebuilder:validation:Optional Buckets []string `json:"buckets"` // used to define buckets of histogram when using latency expression // +kubebuilder:validation:Optional Expr string `json:"expr"` }
func (*ExprBlock) ComputeExpr ¶
func (*ExprBlock) ComputeQuantile ¶
func (*ExprBlock) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ExprBlock.
func (*ExprBlock) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ExprBlock) GetShortWindow ¶
type LatencyTarget ¶
func (*LatencyTarget) DeepCopy ¶
func (in *LatencyTarget) DeepCopy() *LatencyTarget
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LatencyTarget.
func (*LatencyTarget) DeepCopyInto ¶
func (in *LatencyTarget) DeepCopyInto(out *LatencyTarget)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Objectives ¶
type Objectives struct { Availability string `json:"availability"` Latency []LatencyTarget `json:"latency"` Window string `json:"window"` }
func (*Objectives) DeepCopy ¶
func (in *Objectives) DeepCopy() *Objectives
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Objectives.
func (*Objectives) DeepCopyInto ¶
func (in *Objectives) DeepCopyInto(out *Objectives)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Slo ¶
type Slo struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec SloSpec `json:"spec,omitempty"` Status SloStatus `json:"status,omitempty"` }
Slo is the Schema for the sloes API
func (*Slo) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Slo.
func (*Slo) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Slo) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type SloList ¶
type SloList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []Slo `json:"items"` }
SloList contains a list of Slo
func (*SloList) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SloList.
func (*SloList) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*SloList) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type SloSpec ¶
type SloSpec struct { Objectives Objectives `json:"objectives"` // +kubebuilder:validation:Optional TrafficRateRecord ExprBlock `json:"trafficRateRecord"` // +kubebuilder:validation:Optional ErrorRateRecord ExprBlock `json:"errorRateRecord"` // +kubebuilder:validation:Optional LatencyRecord ExprBlock `json:"latencyRecord"` // +kubebuilder:validation:Optional LatencyQuantileRecord ExprBlock `json:"latencyQuantileRecord"` // +kubebuilder:validation:Optional Labels map[string]string `json:"labels"` // +kubebuilder:validation:Optional Annotations map[string]string `json:"annotations"` }
SloSpec defines the desired state of Slo
func (*SloSpec) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SloSpec.
func (*SloSpec) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SloStatus ¶
type SloStatus struct { }
SloStatus defines the observed state of Slo
func (*SloStatus) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SloStatus.
func (*SloStatus) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Window ¶
type Window struct { Duration string `json:"duration"` Consumption string `json:"consumption"` Notification string `json:"notification"` }
func (*Window) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Window.
func (*Window) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.