Documentation ¶
Overview ¶
Package v1alpha1 contains API Schema definitions for the http v1alpha1 API group +kubebuilder:object:generate=true +groupName=http.keda.sh
Index ¶
- Variables
- type HTTPScaledObject
- func (httpso *HTTPScaledObject) AddCondition(condition HTTPScaledObjectCondition) *HTTPScaledObject
- func (in *HTTPScaledObject) DeepCopy() *HTTPScaledObject
- func (in *HTTPScaledObject) DeepCopyInto(out *HTTPScaledObject)
- func (in *HTTPScaledObject) DeepCopyObject() runtime.Object
- func (httpso *HTTPScaledObject) SaveStatus(ctx context.Context, logger logr.Logger, cl client.Client)
- type HTTPScaledObjectCondition
- type HTTPScaledObjectConditionReason
- type HTTPScaledObjectCreationStatus
- type HTTPScaledObjectList
- type HTTPScaledObjectSpec
- type HTTPScaledObjectStatus
- type ReplicaStruct
- type ScaleTargetRef
Constants ¶
This section is empty.
Variables ¶
var ( // GroupVersion is group version used to register these objects GroupVersion = schema.GroupVersion{Group: "http.keda.sh", 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 HTTPScaledObject ¶
type HTTPScaledObject struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec HTTPScaledObjectSpec `json:"spec,omitempty"` Status HTTPScaledObjectStatus `json:"status,omitempty"` }
func (*HTTPScaledObject) AddCondition ¶ added in v0.1.0
func (httpso *HTTPScaledObject) AddCondition(condition HTTPScaledObjectCondition) *HTTPScaledObject
AddCondition adds a new condition to the HTTPScaledObject
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
func (*HTTPScaledObject) SaveStatus ¶ added in v0.1.0
func (httpso *HTTPScaledObject) SaveStatus( ctx context.Context, logger logr.Logger, cl client.Client, )
SaveStatus will trigger an object update to save the current status conditions
type HTTPScaledObjectCondition ¶ added in v0.1.0
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"` // The reason for the condition's last transition. // +optional Reason HTTPScaledObjectConditionReason `json:"reason,omitempty" description:"one-word CamelCase reason for the condition's last transition"` // A human readable message indicating details about the transition. // +optional Message string `json:"message,omitempty" description:"human-readable message indicating details about last transition"` }
Condition to store the condition state
func CreateCondition ¶ added in v0.1.0
func CreateCondition( condType HTTPScaledObjectCreationStatus, status metav1.ConditionStatus, reason HTTPScaledObjectConditionReason, ) *HTTPScaledObjectCondition
CreateCondition initializes a new status condition
func (*HTTPScaledObjectCondition) DeepCopy ¶ added in v0.1.0
func (in *HTTPScaledObjectCondition) DeepCopy() *HTTPScaledObjectCondition
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HTTPScaledObjectCondition.
func (*HTTPScaledObjectCondition) DeepCopyInto ¶ added in v0.1.0
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) SetMessage ¶ added in v0.1.0
func (c *HTTPScaledObjectCondition) SetMessage(message string) *HTTPScaledObjectCondition
SetMessage sets the optional reason for the condition
type HTTPScaledObjectConditionReason ¶ added in v0.1.0
type HTTPScaledObjectConditionReason string
HTTPScaledObjectConditionReason describes the reason why the condition transitioned +kubebuilder:validation:Enum=ErrorCreatingAppScaledObject;AppScaledObjectCreated;TerminatingResources;AppScaledObjectTerminated;AppScaledObjectTerminationError;PendingCreation;HTTPScaledObjectIsReady;
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 +kubebuilder:validation:Enum=Created;Error;Pending;Unknown;Terminating;Terminated;Ready
const ( // Created indicates the resource has been created Created HTTPScaledObjectCreationStatus = "Created" // Terminated indicates the resource has been terminated Terminated HTTPScaledObjectCreationStatus = "Terminated" // Error indicates the resource had an error Error HTTPScaledObjectCreationStatus = "Error" // Pending indicates the resource hasn't been created Pending HTTPScaledObjectCreationStatus = "Pending" // Terminating indicates that the resource is marked for deletion but hasn't // been deleted yet Terminating HTTPScaledObjectCreationStatus = "Terminating" // Unknown indicates the status is unavailable Unknown HTTPScaledObjectCreationStatus = "Unknown" // 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 host to route. All requests with this host in the "Host" // header will be routed to the Service and Port specified // in the scaleTargetRef Host string `json:"host"` // The name of the deployment to route HTTP requests to (and to autoscale). Either this // or Image must be set ScaleTargetRef *ScaleTargetRef `json:"scaleTargetRef"` // (optional) Replica information // +optional Replicas ReplicaStruct `json:"replicas,omitempty"` // (optional) 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 x)"` }
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 { // List of auditable conditions of the operator Conditions []HTTPScaledObjectCondition `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 ReplicaStruct ¶ added in v0.1.0
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)"` }
func (*ReplicaStruct) DeepCopy ¶ added in v0.2.0
func (in *ReplicaStruct) DeepCopy() *ReplicaStruct
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ReplicaStruct.
func (*ReplicaStruct) DeepCopyInto ¶ added in v0.2.0
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 ¶ added in v0.1.0
type ScaleTargetRef struct { // The name of the deployment to scale according to HTTP traffic Deployment string `json:"deployment"` // The name of the service to route to Service string `json:"service"` // The port to route to Port int32 `json:"port"` }
ScaleTargetRef contains all the details about an HTTP application to scale and route to
func (*ScaleTargetRef) DeepCopy ¶ added in v0.2.0
func (in *ScaleTargetRef) DeepCopy() *ScaleTargetRef
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ScaleTargetRef.
func (*ScaleTargetRef) DeepCopyInto ¶ added in v0.2.0
func (in *ScaleTargetRef) DeepCopyInto(out *ScaleTargetRef)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.