Documentation
¶
Overview ¶
Package v1alpha1 contains API Schema definitions for the http v1alpha1 API group +kubebuilder:object:generate=true +groupName=http.keda.sh
Index ¶
- Variables
- func Resource(resource string) schema.GroupResource
- type ColdStartTimeoutFailoverRef
- func (in *ColdStartTimeoutFailoverRef) DeepCopy() *ColdStartTimeoutFailoverRef
- func (in *ColdStartTimeoutFailoverRef) DeepCopyInto(out *ColdStartTimeoutFailoverRef)
- func (s *ColdStartTimeoutFailoverRef) GetPort() int32
- func (s *ColdStartTimeoutFailoverRef) GetPortName() string
- func (s *ColdStartTimeoutFailoverRef) GetServiceName() string
- type ConcurrencyMetricSpec
- type Conditions
- type HTTPScaledObject
- type HTTPScaledObjectCondition
- type HTTPScaledObjectConditionReason
- type HTTPScaledObjectCreationStatus
- type HTTPScaledObjectList
- type HTTPScaledObjectSpec
- type HTTPScaledObjectStatus
- type HTTPScaledObjectTimeoutsSpec
- type RateMetricSpec
- type Ref
- type ReplicaStruct
- type ScaleTargetRef
- type ScalingMetricSpec
Constants ¶
This section is empty.
Variables ¶
var ( // SchemeGroupVersion is group version used to register these objects SchemeGroupVersion = schema.GroupVersion{Group: "http.keda.sh", Version: "v1alpha1"} // SchemeBuilder is used to add go types to the GroupVersionKind scheme SchemeBuilder = &scheme.Builder{GroupVersion: SchemeGroupVersion} // AddToScheme adds the types in this group-version to the given scheme. AddToScheme = SchemeBuilder.AddToScheme )
Functions ¶
func Resource ¶
func Resource(resource string) schema.GroupResource
Resource takes an unqualified resource and returns a Group qualified GroupResource
Types ¶
type ColdStartTimeoutFailoverRef ¶ added in v0.11.0
type ColdStartTimeoutFailoverRef struct {
// The name of the service to route to
Service string `json:"service"`
// The port to route to
Port int32 `json:"port,omitempty"`
// The port to route to referenced by name
PortName string `json:"portName,omitempty"`
// The timeout in seconds to wait before routing to the failover service (Default 30)
// +kubebuilder:default=30
// +optional
TimeoutSeconds int32 `json:"timeoutSeconds,omitempty"`
}
ColdStartTimeoutFailoverRef contains all the details about an HTTP application to scale and route to
func (*ColdStartTimeoutFailoverRef) DeepCopy ¶ added in v0.11.0
func (in *ColdStartTimeoutFailoverRef) DeepCopy() *ColdStartTimeoutFailoverRef
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ColdStartTimeoutFailoverRef.
func (*ColdStartTimeoutFailoverRef) DeepCopyInto ¶ added in v0.11.0
func (in *ColdStartTimeoutFailoverRef) DeepCopyInto(out *ColdStartTimeoutFailoverRef)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ColdStartTimeoutFailoverRef) GetPort ¶ added in v0.11.0
func (s *ColdStartTimeoutFailoverRef) GetPort() int32
func (*ColdStartTimeoutFailoverRef) GetPortName ¶ added in v0.11.0
func (s *ColdStartTimeoutFailoverRef) GetPortName() string
func (*ColdStartTimeoutFailoverRef) GetServiceName ¶ added in v0.11.0
func (s *ColdStartTimeoutFailoverRef) GetServiceName() string
type ConcurrencyMetricSpec ¶ added in v0.8.0
type ConcurrencyMetricSpec struct {
// Target value for rate scaling
// +kubebuilder:default=100
// +optional
TargetValue int `json:"targetValue" description:"Target value for concurrency scaling"`
}
ConcurrencyMetricSpec defines the concurrency scaling
func (*ConcurrencyMetricSpec) DeepCopy ¶ added in v0.8.0
func (in *ConcurrencyMetricSpec) DeepCopy() *ConcurrencyMetricSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConcurrencyMetricSpec.
func (*ConcurrencyMetricSpec) DeepCopyInto ¶ added in v0.8.0
func (in *ConcurrencyMetricSpec) DeepCopyInto(out *ConcurrencyMetricSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Conditions ¶ added in v0.8.0
type Conditions []HTTPScaledObjectCondition
func GetInitializedConditions ¶ added in v0.8.0
func GetInitializedConditions() *Conditions
GetInitializedConditions returns Conditions initialized to the default -> Status: Unknown
func (Conditions) DeepCopy ¶ added in v0.8.0
func (in Conditions) DeepCopy() Conditions
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Conditions.
func (Conditions) DeepCopyInto ¶ added in v0.8.0
func (in Conditions) DeepCopyInto(out *Conditions)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Conditions) GetReadyCondition ¶ added in v0.8.0
func (c *Conditions) GetReadyCondition() HTTPScaledObjectCondition
GetReadyCondition returns Condition of type Ready
type HTTPScaledObject ¶
type HTTPScaledObject struct {
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`
Spec HTTPScaledObjectSpec `json:"spec,omitempty"`
Status HTTPScaledObjectStatus `json:"status,omitempty"`
}
HTTPScaledObject is the Schema for the httpscaledobjects API
func (*HTTPScaledObject) DeepCopy ¶
func (in *HTTPScaledObject) DeepCopy() *HTTPScaledObject
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPScaledObject.
func (*HTTPScaledObject) DeepCopyInto ¶
func (in *HTTPScaledObject) DeepCopyInto(out *HTTPScaledObject)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*HTTPScaledObject) DeepCopyObject ¶
func (in *HTTPScaledObject) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type HTTPScaledObjectCondition ¶
type HTTPScaledObjectCondition struct {
// Timestamp of the condition
// +optional
Timestamp string `json:"timestamp" description:"Timestamp of this condition"`
// Type of condition
// +required
Type HTTPScaledObjectCreationStatus `json:"type" description:"type of status condition"`
// Status of the condition, one of True, False, Unknown.
// +required
Status metav1.ConditionStatus `json:"status" description:"status of the condition, one of True, False, Unknown"`
// Reason for the condition's last transition.
// +optional
Reason HTTPScaledObjectConditionReason `json:"reason,omitempty" description:"one-word CamelCase reason for the condition's last transition"`
// Message indicating details about the transition.
// +optional
Message string `json:"message,omitempty" description:"human-readable message indicating details about last transition"`
}
HTTPScaledObjectCondition stores the condition state
func (*HTTPScaledObjectCondition) DeepCopy ¶
func (in *HTTPScaledObjectCondition) DeepCopy() *HTTPScaledObjectCondition
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPScaledObjectCondition.
func (*HTTPScaledObjectCondition) DeepCopyInto ¶
func (in *HTTPScaledObjectCondition) DeepCopyInto(out *HTTPScaledObjectCondition)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*HTTPScaledObjectCondition) IsFalse ¶ added in v0.8.0
func (c *HTTPScaledObjectCondition) IsFalse() bool
IsFalse is true if the condition is False
func (*HTTPScaledObjectCondition) IsTrue ¶ added in v0.8.0
func (c *HTTPScaledObjectCondition) IsTrue() bool
IsTrue is true if the condition is True
type HTTPScaledObjectConditionReason ¶
type HTTPScaledObjectConditionReason string
HTTPScaledObjectConditionReason describes the reason why the condition transitioned
const ( ErrorCreatingAppScaledObject HTTPScaledObjectConditionReason = "ErrorCreatingAppScaledObject" AppScaledObjectCreated HTTPScaledObjectConditionReason = "AppScaledObjectCreated" TerminatingResources HTTPScaledObjectConditionReason = "TerminatingResources" AppScaledObjectTerminated HTTPScaledObjectConditionReason = "AppScaledObjectTerminated" AppScaledObjectTerminationError HTTPScaledObjectConditionReason = "AppScaledObjectTerminationError" PendingCreation HTTPScaledObjectConditionReason = "PendingCreation" HTTPScaledObjectIsReady HTTPScaledObjectConditionReason = "HTTPScaledObjectIsReady" )
type HTTPScaledObjectCreationStatus ¶
type HTTPScaledObjectCreationStatus string
HTTPScaledObjectCreationStatus describes the creation status of the scaler's additional resources such as Services, Ingresses and Deployments
const ( // Ready indicates the object is fully created Ready HTTPScaledObjectCreationStatus = "Ready" )
type HTTPScaledObjectList ¶
type HTTPScaledObjectList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []HTTPScaledObject `json:"items"`
}
HTTPScaledObjectList contains a list of HTTPScaledObject
func (*HTTPScaledObjectList) DeepCopy ¶
func (in *HTTPScaledObjectList) DeepCopy() *HTTPScaledObjectList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPScaledObjectList.
func (*HTTPScaledObjectList) DeepCopyInto ¶
func (in *HTTPScaledObjectList) DeepCopyInto(out *HTTPScaledObjectList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*HTTPScaledObjectList) DeepCopyObject ¶
func (in *HTTPScaledObjectList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type HTTPScaledObjectSpec ¶
type HTTPScaledObjectSpec struct {
// The hosts to route. All requests which the "Host" header
// matches any .spec.hosts (and the Request Target matches any
// .spec.pathPrefixes) will be routed to the Service and Port specified in
// the scaleTargetRef.
Hosts []string `json:"hosts,omitempty"`
// The paths to route. All requests which the Request Target matches any
// .spec.pathPrefixes (and the "Host" header matches any .spec.hosts)
// will be routed to the Service and Port specified in
// the scaleTargetRef.
// +optional
PathPrefixes []string `json:"pathPrefixes,omitempty"`
// The name of the deployment to route HTTP requests to (and to autoscale).
// Including validation as a requirement to define either the PortName or the Port
// +kubebuilder:validation:XValidation:rule="has(self.portName) != has(self.port)",message="must define either the 'portName' or the 'port'"
ScaleTargetRef ScaleTargetRef `json:"scaleTargetRef"`
// (optional) The name of the failover service to route HTTP requests to when the target is not available
// +optional
// +kubebuilder:validation:XValidation:rule="has(self.portName) != has(self.port)",message="must define either the 'portName' or the 'port'"
ColdStartTimeoutFailoverRef *ColdStartTimeoutFailoverRef `json:"coldStartTimeoutFailoverRef,omitempty"`
// (optional) Replica information
// +optional
Replicas *ReplicaStruct `json:"replicas,omitempty"`
// (optional) DEPRECATED (use ScalingMetric instead) Target metric value
// +optional
TargetPendingRequests *int32 `json:"targetPendingRequests,omitempty" description:"The target metric value for the HPA (Default 100)"`
// (optional) Cooldown period value
// +optional
CooldownPeriod *int32 `json:"scaledownPeriod,omitempty" description:"Cooldown period (seconds) for resources to scale down (Default 300)"`
// (optional) Initial period before scaling
// +optional
InitialCooldownPeriod *int32 `json:"initialCooldownPeriod,omitempty" description:"Initial period (seconds) before scaling (Default 0)"`
// (optional) Configuration for the metric used for scaling
// +optional
ScalingMetric *ScalingMetricSpec `` /* 127-byte string literal not displayed */
// (optional) Timeouts that override the global ones
// +optional
Timeouts *HTTPScaledObjectTimeoutsSpec `json:"timeouts,omitempty" description:"Timeouts that override the global ones"`
}
HTTPScaledObjectSpec defines the desired state of HTTPScaledObject
func (*HTTPScaledObjectSpec) DeepCopy ¶
func (in *HTTPScaledObjectSpec) DeepCopy() *HTTPScaledObjectSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPScaledObjectSpec.
func (*HTTPScaledObjectSpec) DeepCopyInto ¶
func (in *HTTPScaledObjectSpec) DeepCopyInto(out *HTTPScaledObjectSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type HTTPScaledObjectStatus ¶
type HTTPScaledObjectStatus struct {
// TargetWorkload reflects details about the scaled workload.
// +optional
TargetWorkload string `json:"targetWorkload,omitempty" description:"It reflects details about the scaled workload"`
// TargetService reflects details about the scaled service.
// +optional
TargetService string `json:"targetService,omitempty" description:"It reflects details about the scaled service"`
// Conditions of the operator
Conditions Conditions `json:"conditions,omitempty" description:"List of auditable conditions of the operator"`
}
HTTPScaledObjectStatus defines the observed state of HTTPScaledObject
func (*HTTPScaledObjectStatus) DeepCopy ¶
func (in *HTTPScaledObjectStatus) DeepCopy() *HTTPScaledObjectStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPScaledObjectStatus.
func (*HTTPScaledObjectStatus) DeepCopyInto ¶
func (in *HTTPScaledObjectStatus) DeepCopyInto(out *HTTPScaledObjectStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type HTTPScaledObjectTimeoutsSpec ¶ added in v0.11.0
type HTTPScaledObjectTimeoutsSpec struct {
// How long to wait for the backing workload to have 1 or more replicas before connecting and sending the HTTP request (Default is set by the KEDA_CONDITION_WAIT_TIMEOUT environment variable)
// +optional
ConditionWait metav1.Duration `` /* 150-byte string literal not displayed */
// How long to wait between when the HTTP request is sent to the backing app and when response headers need to arrive (Default is set by the KEDA_RESPONSE_HEADER_TIMEOUT environment variable)
// +optional
ResponseHeader metav1.Duration `` /* 150-byte string literal not displayed */
}
HTTPScaledObjectTimeoutsSpec defines timeouts that override the global ones
func (*HTTPScaledObjectTimeoutsSpec) DeepCopy ¶ added in v0.11.0
func (in *HTTPScaledObjectTimeoutsSpec) DeepCopy() *HTTPScaledObjectTimeoutsSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPScaledObjectTimeoutsSpec.
func (*HTTPScaledObjectTimeoutsSpec) DeepCopyInto ¶ added in v0.11.0
func (in *HTTPScaledObjectTimeoutsSpec) DeepCopyInto(out *HTTPScaledObjectTimeoutsSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type RateMetricSpec ¶ added in v0.8.0
type RateMetricSpec struct {
// Target value for rate scaling
// +kubebuilder:default=100
// +optional
TargetValue int `json:"targetValue" description:"Target value for rate scaling"`
// Time window for rate calculation
// +kubebuilder:default="1m"
// +optional
Window metav1.Duration `json:"window" description:"Time window for rate calculation"`
// Time granularity for rate calculation
// +kubebuilder:default="1s"
// +optional
Granularity metav1.Duration `json:"granularity" description:"Time granularity for rate calculation"`
}
RateMetricSpec defines the concurrency scaling
func (*RateMetricSpec) DeepCopy ¶ added in v0.8.0
func (in *RateMetricSpec) DeepCopy() *RateMetricSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RateMetricSpec.
func (*RateMetricSpec) DeepCopyInto ¶ added in v0.8.0
func (in *RateMetricSpec) DeepCopyInto(out *RateMetricSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ReplicaStruct ¶
type ReplicaStruct struct {
// Minimum amount of replicas to have in the deployment (Default 0)
Min *int32 `json:"min,omitempty" description:"Minimum amount of replicas to have in the deployment (Default 0)"`
// Maximum amount of replicas to have in the deployment (Default 100)
Max *int32 `json:"max,omitempty" description:"Maximum amount of replicas to have in the deployment (Default 100)"`
}
ReplicaStruct contains the minimum and maximum amount of replicas to have in the deployment
func (*ReplicaStruct) DeepCopy ¶
func (in *ReplicaStruct) DeepCopy() *ReplicaStruct
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ReplicaStruct.
func (*ReplicaStruct) DeepCopyInto ¶
func (in *ReplicaStruct) DeepCopyInto(out *ReplicaStruct)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ScaleTargetRef ¶
type ScaleTargetRef struct {
// +optional
Name string `json:"name"`
// +optional
APIVersion string `json:"apiVersion,omitempty"`
// +optional
Kind string `json:"kind,omitempty"`
// The name of the service to route to
Service string `json:"service"`
// The port to route to
Port int32 `json:"port,omitempty"`
// The port to route to referenced by name
PortName string `json:"portName,omitempty"`
}
ScaleTargetRef contains all the details about an HTTP application to scale and route to
func (*ScaleTargetRef) DeepCopy ¶
func (in *ScaleTargetRef) DeepCopy() *ScaleTargetRef
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ScaleTargetRef.
func (*ScaleTargetRef) DeepCopyInto ¶
func (in *ScaleTargetRef) DeepCopyInto(out *ScaleTargetRef)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (ScaleTargetRef) GetPort ¶ added in v0.11.0
func (s ScaleTargetRef) GetPort() int32
func (ScaleTargetRef) GetPortName ¶ added in v0.11.0
func (s ScaleTargetRef) GetPortName() string
func (ScaleTargetRef) GetServiceName ¶ added in v0.11.0
func (s ScaleTargetRef) GetServiceName() string
type ScalingMetricSpec ¶ added in v0.8.0
type ScalingMetricSpec struct {
// Scaling based on concurrent requests for a given target
Concurrency *ConcurrencyMetricSpec `` /* 148-byte string literal not displayed */
// Scaling based the average rate during an specific time window for a given target
Rate *RateMetricSpec `` /* 173-byte string literal not displayed */
}
ScalingMetricSpec contains the scaling calculation type
func (*ScalingMetricSpec) DeepCopy ¶ added in v0.8.0
func (in *ScalingMetricSpec) DeepCopy() *ScalingMetricSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ScalingMetricSpec.
func (*ScalingMetricSpec) DeepCopyInto ¶ added in v0.8.0
func (in *ScalingMetricSpec) DeepCopyInto(out *ScalingMetricSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.