Documentation ¶
Overview ¶
Package v1alpha1 contains API Schema definitions for the limitador v1alpha1 API group +kubebuilder:object:generate=true +groupName=limitador.kuadrant.io
Index ¶
- Constants
- Variables
- type DiskOptimizeType
- type DiskSpec
- type Limitador
- func (in *Limitador) DeepCopy() *Limitador
- func (in *Limitador) DeepCopyInto(out *Limitador)
- func (in *Limitador) DeepCopyObject() runtime.Object
- func (l *Limitador) GRPCPort() int32
- func (l *Limitador) GetReplicas() int32
- func (l *Limitador) GetResourceRequirements() *corev1.ResourceRequirements
- func (l *Limitador) HTTPPort() int32
- func (l *Limitador) Limits() []RateLimit
- type LimitadorList
- type LimitadorService
- type LimitadorSpec
- type LimitadorStatus
- type Listener
- type PVCGenericSpec
- type PersistentVolumeClaimResources
- type PodDisruptionBudgetType
- type Ports
- type RateLimit
- type RateLimitHeadersType
- type Redis
- type RedisCached
- type RedisCachedOptions
- type Storage
- type Telemetry
- type Tracing
- type TransportProtocol
- type VerbosityLevel
Constants ¶
Variables ¶
var ( // GroupVersion is group version used to register these objects GroupVersion = schema.GroupVersion{Group: "limitador.kuadrant.io", 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 )
Functions ¶
This section is empty.
Types ¶
type DiskOptimizeType ¶ added in v0.7.0
type DiskOptimizeType string
DiskOptimizeType defines the valid options for "optimize" option of the disk persistence type +kubebuilder:validation:Enum=throughput;disk
const ( DiskOptimizeTypeThroughput DiskOptimizeType = "throughput" DiskOptimizeTypeDisk DiskOptimizeType = "disk" )
type DiskSpec ¶ added in v0.7.0
type DiskSpec struct { // +optional PVC *PVCGenericSpec `json:"persistentVolumeClaim,omitempty"` // +optional Optimize *DiskOptimizeType `json:"optimize,omitempty"` }
func (*DiskSpec) DeepCopy ¶ added in v0.7.0
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DiskSpec.
func (*DiskSpec) DeepCopyInto ¶ added in v0.7.0
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Limitador ¶
type Limitador struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` // +kubebuilder:validation:Optional // +kubebuilder:validation:XValidation:rule="(!has(self.storage) || !has(self.storage.disk)) || (!has(self.replicas) || self.replicas < 2)",message="disk storage does not allow multiple replicas" Spec LimitadorSpec `json:"spec,omitempty"` Status LimitadorStatus `json:"status,omitempty"` }
Limitador is the Schema for the limitadors API
func (*Limitador) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Limitador.
func (*Limitador) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Limitador) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*Limitador) GetReplicas ¶ added in v0.8.0
func (*Limitador) GetResourceRequirements ¶ added in v0.6.0
func (l *Limitador) GetResourceRequirements() *corev1.ResourceRequirements
type LimitadorList ¶
type LimitadorList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []Limitador `json:"items"` }
LimitadorList contains a list of Limitador
func (*LimitadorList) DeepCopy ¶
func (in *LimitadorList) DeepCopy() *LimitadorList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LimitadorList.
func (*LimitadorList) DeepCopyInto ¶
func (in *LimitadorList) DeepCopyInto(out *LimitadorList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LimitadorList) DeepCopyObject ¶
func (in *LimitadorList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type LimitadorService ¶
type LimitadorService struct { Host string `json:"host,omitempty"` Ports Ports `json:"ports,omitempty"` }
func (*LimitadorService) DeepCopy ¶
func (in *LimitadorService) DeepCopy() *LimitadorService
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LimitadorService.
func (*LimitadorService) DeepCopyInto ¶
func (in *LimitadorService) DeepCopyInto(out *LimitadorService)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LimitadorSpec ¶
type LimitadorSpec struct { // +optional Affinity *corev1.Affinity `json:"affinity,omitempty"` // +optional Replicas *int `json:"replicas,omitempty"` // [Deprecated] Use spec.image instead. // Docker tag used as limitador image. The repo is hardcoded to quay.io/kuadrant/limitador // +deprecated // +optional Version *string `json:"version,omitempty"` // +optional Listener *Listener `json:"listener,omitempty"` // +optional Storage *Storage `json:"storage,omitempty"` // +optional RateLimitHeaders *RateLimitHeadersType `json:"rateLimitHeaders,omitempty"` // +optional Telemetry *Telemetry `json:"telemetry,omitempty"` // +optional Tracing *Tracing `json:"tracing,omitempty"` // +optional Limits []RateLimit `json:"limits,omitempty"` // +optional PodDisruptionBudget *PodDisruptionBudgetType `json:"pdb,omitempty"` // +optional ResourceRequirements *corev1.ResourceRequirements `json:"resourceRequirements,omitempty"` // Sets the level of verbosity // +optional Verbosity *VerbosityLevel `json:"verbosity,omitempty"` // +optional Image *string `json:"image,omitempty"` // +optional ImagePullSecrets []corev1.LocalObjectReference `json:"imagePullSecrets,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,15,rep,name=imagePullSecrets"` }
LimitadorSpec defines the desired state of Limitador
func (*LimitadorSpec) DeepCopy ¶
func (in *LimitadorSpec) DeepCopy() *LimitadorSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LimitadorSpec.
func (*LimitadorSpec) DeepCopyInto ¶
func (in *LimitadorSpec) DeepCopyInto(out *LimitadorSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LimitadorStatus ¶
type LimitadorStatus struct { // ObservedGeneration reflects the generation of the most recently observed spec. // +optional ObservedGeneration int64 `json:"observedGeneration,omitempty"` // Represents the observations of a foo's current state. // Known .status.conditions.type are: "Ready" // +patchMergeKey=type // +patchStrategy=merge // +listType=map // +listMapKey=type Conditions []metav1.Condition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,1,rep,name=conditions"` // Service provides information about the service exposing limitador API // +optional Service *LimitadorService `json:"service,omitempty"` }
LimitadorStatus defines the observed state of Limitador
func (*LimitadorStatus) DeepCopy ¶
func (in *LimitadorStatus) DeepCopy() *LimitadorStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LimitadorStatus.
func (*LimitadorStatus) DeepCopyInto ¶
func (in *LimitadorStatus) DeepCopyInto(out *LimitadorStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LimitadorStatus) Equals ¶ added in v0.4.0
func (s *LimitadorStatus) Equals(other *LimitadorStatus, logger logr.Logger) bool
type Listener ¶
type Listener struct { // +optional HTTP *TransportProtocol `json:"http,omitempty"` // +optional GRPC *TransportProtocol `json:"grpc,omitempty"` }
func (*Listener) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Listener.
func (*Listener) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type PVCGenericSpec ¶ added in v0.7.0
type PVCGenericSpec struct { // +optional StorageClassName *string `json:"storageClassName,omitempty"` // Resources represents the minimum resources the volume should have. // Ignored when VolumeName field is set // +optional Resources *PersistentVolumeClaimResources `json:"resources,omitempty"` // VolumeName is the binding reference to the PersistentVolume backing this claim. // +optional VolumeName *string `json:"volumeName,omitempty"` }
func (*PVCGenericSpec) DeepCopy ¶ added in v0.7.0
func (in *PVCGenericSpec) DeepCopy() *PVCGenericSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PVCGenericSpec.
func (*PVCGenericSpec) DeepCopyInto ¶ added in v0.7.0
func (in *PVCGenericSpec) DeepCopyInto(out *PVCGenericSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type PersistentVolumeClaimResources ¶ added in v0.7.0
type PersistentVolumeClaimResources struct { // Storage Resource requests to be used on the PersistentVolumeClaim. // To learn more about resource requests see: // https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/ Requests resource.Quantity `json:"requests"` // Should this be a string or a resoure.Quantity? it seems it is serialized as a string }
PersistentVolumeClaimResources defines the resources configuration of the backup data destination PersistentVolumeClaim
func (*PersistentVolumeClaimResources) DeepCopy ¶ added in v0.7.0
func (in *PersistentVolumeClaimResources) DeepCopy() *PersistentVolumeClaimResources
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PersistentVolumeClaimResources.
func (*PersistentVolumeClaimResources) DeepCopyInto ¶ added in v0.7.0
func (in *PersistentVolumeClaimResources) DeepCopyInto(out *PersistentVolumeClaimResources)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type PodDisruptionBudgetType ¶ added in v0.6.0
type PodDisruptionBudgetType struct { // are unavailable after the eviction, i.e. even in absence of // the evicted pod. For example, one can prevent all voluntary evictions // by specifying 0. This is a mutually exclusive setting with "minAvailable". // +optional MaxUnavailable *intstr.IntOrString `json:"maxUnavailable,omitempty"` // An eviction is allowed if at least "minAvailable" limitador pods will // still be available after the eviction, i.e. even in the absence of // the evicted pod. So for example you can prevent all voluntary // evictions by specifying "100%". // +optional MinAvailable *intstr.IntOrString `json:"minAvailable,omitempty"` }
func (*PodDisruptionBudgetType) DeepCopy ¶ added in v0.6.0
func (in *PodDisruptionBudgetType) DeepCopy() *PodDisruptionBudgetType
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PodDisruptionBudgetType.
func (*PodDisruptionBudgetType) DeepCopyInto ¶ added in v0.6.0
func (in *PodDisruptionBudgetType) DeepCopyInto(out *PodDisruptionBudgetType)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Ports ¶
func (*Ports) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Ports.
func (*Ports) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type RateLimit ¶
type RateLimit struct { Conditions []string `json:"conditions"` MaxValue int `json:"max_value"` Namespace string `json:"namespace"` Seconds int `json:"seconds"` Variables []string `json:"variables"` Name string `json:"name,omitempty"` }
RateLimit defines the desired Limitador limit
func (*RateLimit) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RateLimit.
func (*RateLimit) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type RateLimitHeadersType ¶ added in v0.5.0
type RateLimitHeadersType string
RateLimitHeadersType defines the valid options for the --rate-limit-headers arg +kubebuilder:validation:Enum=NONE;DRAFT_VERSION_03
const ( RateLimitHeadersTypeNONE RateLimitHeadersType = "NONE" RateLimitHeadersTypeDraft03 RateLimitHeadersType = "DRAFT_VERSION_03" )
type Redis ¶ added in v0.4.0
type Redis struct { // +ConfigSecretRef refers to the secret holding the URL for Redis. // +optional ConfigSecretRef *corev1.LocalObjectReference `json:"configSecretRef,omitempty"` }
func (*Redis) DeepCopy ¶ added in v0.4.0
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Redis.
func (*Redis) DeepCopyInto ¶ added in v0.4.0
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type RedisCached ¶ added in v0.4.0
type RedisCached struct { // +ConfigSecretRef refers to the secret holding the URL for Redis. // +optional ConfigSecretRef *corev1.LocalObjectReference `json:"configSecretRef,omitempty"` // +optional Options *RedisCachedOptions `json:"options,omitempty"` }
func (*RedisCached) DeepCopy ¶ added in v0.4.0
func (in *RedisCached) DeepCopy() *RedisCached
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RedisCached.
func (*RedisCached) DeepCopyInto ¶ added in v0.4.0
func (in *RedisCached) DeepCopyInto(out *RedisCached)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type RedisCachedOptions ¶ added in v0.4.0
type RedisCachedOptions struct { // +optional // FlushPeriod for counters in milliseconds [default: 1000] FlushPeriod *int `json:"flush-period,omitempty"` // +optional // MaxCached refers to the maximum amount of counters cached [default: 10000] MaxCached *int `json:"max-cached,omitempty"` // +optional // ResponseTimeout defines the timeout for Redis commands in milliseconds [default: 350] ResponseTimeout *int `json:"response-timeout,omitempty"` // +optional // BatchSize defines the size of entries to flush in as single flush [default: 100] BatchSize *int `json:"batch-size,omitempty"` }
func (*RedisCachedOptions) DeepCopy ¶ added in v0.4.0
func (in *RedisCachedOptions) DeepCopy() *RedisCachedOptions
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RedisCachedOptions.
func (*RedisCachedOptions) DeepCopyInto ¶ added in v0.4.0
func (in *RedisCachedOptions) DeepCopyInto(out *RedisCachedOptions)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Storage ¶ added in v0.4.0
type Storage struct { // +optional Redis *Redis `json:"redis,omitempty"` // +optional RedisCached *RedisCached `json:"redis-cached,omitempty"` // +optional Disk *DiskSpec `json:"disk,omitempty"` }
Storage contains the options for Limitador counters database or in-memory data storage
func (*Storage) DeepCopy ¶ added in v0.4.0
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Storage.
func (*Storage) DeepCopyInto ¶ added in v0.4.0
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Telemetry ¶ added in v0.7.0
type Telemetry string
Telemetry defines the level of metrics Limitador will expose to the user +kubebuilder:validation:Enum=basic;exhaustive
type Tracing ¶ added in v0.8.0
type Tracing struct {
Endpoint string `json:"endpoint"`
}
func (*Tracing) DeepCopy ¶ added in v0.9.0
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Tracing.
func (*Tracing) DeepCopyInto ¶ added in v0.9.0
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type TransportProtocol ¶
type TransportProtocol struct { // +optional Port *int32 `json:"port,omitempty"` }
func (*TransportProtocol) DeepCopy ¶
func (in *TransportProtocol) DeepCopy() *TransportProtocol
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TransportProtocol.
func (*TransportProtocol) DeepCopyInto ¶
func (in *TransportProtocol) DeepCopyInto(out *TransportProtocol)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type VerbosityLevel ¶ added in v0.8.0
type VerbosityLevel int
+kubebuilder:validation:Minimum=1 +kubebuilder:validation:Maximum=4