Documentation
¶
Overview ¶
Package v1alpha1 contains API Schema definitions for the decisions v1alpha1 API group. +kubebuilder:object:generate=true +groupName=decisions.cortex
Index ¶
- Variables
- type Flavor
- type SchedulingDecision
- type SchedulingDecisionList
- type SchedulingDecisionPipelineOutputSpec
- type SchedulingDecisionPipelineSpec
- type SchedulingDecisionRequest
- type SchedulingDecisionResult
- type SchedulingDecisionSpec
- type SchedulingDecisionState
- type SchedulingDecisionStatus
- type SchedulingEventType
Constants ¶
This section is empty.
Variables ¶
var ( // GroupVersion is group version used to register these objects. GroupVersion = schema.GroupVersion{Group: "decisions.cortex", 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 Flavor ¶
type Flavor struct {
Name string `json:"name"`
Resources map[string]resource.Quantity `json:"requests,omitempty"`
}
func (*Flavor) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Flavor.
func (*Flavor) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SchedulingDecision ¶
type SchedulingDecision struct {
metav1.TypeMeta `json:",inline"`
// metadata is a standard object metadata
// +optional
metav1.ObjectMeta `json:"metadata,omitempty,omitzero"`
// spec defines the desired state of SchedulingDecision
// +required
Spec SchedulingDecisionSpec `json:"spec"`
// status defines the observed state of SchedulingDecision
// +optional
Status SchedulingDecisionStatus `json:"status,omitempty,omitzero"`
}
SchedulingDecision is the Schema for the schedulingdecisions API
func (*SchedulingDecision) DeepCopy ¶
func (in *SchedulingDecision) DeepCopy() *SchedulingDecision
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SchedulingDecision.
func (*SchedulingDecision) DeepCopyInto ¶
func (in *SchedulingDecision) DeepCopyInto(out *SchedulingDecision)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*SchedulingDecision) DeepCopyObject ¶
func (in *SchedulingDecision) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type SchedulingDecisionList ¶
type SchedulingDecisionList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []SchedulingDecision `json:"items"`
}
SchedulingDecisionList contains a list of SchedulingDecision
func (*SchedulingDecisionList) DeepCopy ¶
func (in *SchedulingDecisionList) DeepCopy() *SchedulingDecisionList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SchedulingDecisionList.
func (*SchedulingDecisionList) DeepCopyInto ¶
func (in *SchedulingDecisionList) DeepCopyInto(out *SchedulingDecisionList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*SchedulingDecisionList) DeepCopyObject ¶
func (in *SchedulingDecisionList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type SchedulingDecisionPipelineOutputSpec ¶
type SchedulingDecisionPipelineOutputSpec struct {
Step string `json:"step"`
Activations map[string]float64 `json:"activations,omitempty"`
}
func (*SchedulingDecisionPipelineOutputSpec) DeepCopy ¶
func (in *SchedulingDecisionPipelineOutputSpec) DeepCopy() *SchedulingDecisionPipelineOutputSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SchedulingDecisionPipelineOutputSpec.
func (*SchedulingDecisionPipelineOutputSpec) DeepCopyInto ¶
func (in *SchedulingDecisionPipelineOutputSpec) DeepCopyInto(out *SchedulingDecisionPipelineOutputSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SchedulingDecisionPipelineSpec ¶
type SchedulingDecisionPipelineSpec struct {
Name string `json:"name"`
Outputs []SchedulingDecisionPipelineOutputSpec `json:"outputs,omitempty"`
}
func (*SchedulingDecisionPipelineSpec) DeepCopy ¶
func (in *SchedulingDecisionPipelineSpec) DeepCopy() *SchedulingDecisionPipelineSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SchedulingDecisionPipelineSpec.
func (*SchedulingDecisionPipelineSpec) DeepCopyInto ¶
func (in *SchedulingDecisionPipelineSpec) DeepCopyInto(out *SchedulingDecisionPipelineSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SchedulingDecisionRequest ¶
type SchedulingDecisionRequest struct {
ID string `json:"id"`
RequestedAt metav1.Time `json:"requestedAt"`
EventType SchedulingEventType `json:"eventType"`
Input map[string]float64 `json:"input,omitempty"`
Pipeline SchedulingDecisionPipelineSpec `json:"pipeline"`
AvailabilityZone string `json:"availabilityZone,omitempty"`
Flavor Flavor `json:"flavor,omitempty"`
}
func (*SchedulingDecisionRequest) DeepCopy ¶
func (in *SchedulingDecisionRequest) DeepCopy() *SchedulingDecisionRequest
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SchedulingDecisionRequest.
func (*SchedulingDecisionRequest) DeepCopyInto ¶
func (in *SchedulingDecisionRequest) DeepCopyInto(out *SchedulingDecisionRequest)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SchedulingDecisionResult ¶
type SchedulingDecisionResult struct {
ID string `json:"id"`
Description string `json:"description,omitempty"`
// Final scores for each host after processing all pipeline steps.
FinalScores map[string]float64 `json:"finalScores,omitempty"`
// Hosts that were deleted during pipeline processing and all steps that attempted to delete them.
DeletedHosts map[string][]string `json:"deletedHosts,omitempty"`
}
SchedulingDecisionResult represents the result of processing a single decision request.
func (*SchedulingDecisionResult) DeepCopy ¶
func (in *SchedulingDecisionResult) DeepCopy() *SchedulingDecisionResult
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SchedulingDecisionResult.
func (*SchedulingDecisionResult) DeepCopyInto ¶
func (in *SchedulingDecisionResult) DeepCopyInto(out *SchedulingDecisionResult)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SchedulingDecisionSpec ¶
type SchedulingDecisionSpec struct {
Decisions []SchedulingDecisionRequest `json:"decisions"`
}
SchedulingDecisionSpec defines the desired state of SchedulingDecision.
func (*SchedulingDecisionSpec) DeepCopy ¶
func (in *SchedulingDecisionSpec) DeepCopy() *SchedulingDecisionSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SchedulingDecisionSpec.
func (*SchedulingDecisionSpec) DeepCopyInto ¶
func (in *SchedulingDecisionSpec) DeepCopyInto(out *SchedulingDecisionSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SchedulingDecisionState ¶
type SchedulingDecisionState string
const ( SchedulingDecisionStateResolved SchedulingDecisionState = "resolved" SchedulingDecisionStateError SchedulingDecisionState = "error" )
type SchedulingDecisionStatus ¶
type SchedulingDecisionStatus struct {
State SchedulingDecisionState `json:"state,omitempty"`
Error string `json:"error,omitempty"`
DecisionCount int `json:"decisionCount,omitempty"`
GlobalDescription string `json:"globalDescription,omitempty"`
Results []SchedulingDecisionResult `json:"results,omitempty"`
}
SchedulingDecisionStatus defines the observed state of SchedulingDecision.
func (*SchedulingDecisionStatus) DeepCopy ¶
func (in *SchedulingDecisionStatus) DeepCopy() *SchedulingDecisionStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SchedulingDecisionStatus.
func (*SchedulingDecisionStatus) DeepCopyInto ¶
func (in *SchedulingDecisionStatus) DeepCopyInto(out *SchedulingDecisionStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SchedulingEventType ¶
type SchedulingEventType string
const ( SchedulingEventTypeLiveMigration SchedulingEventType = "live-migration" // SchedulingEventTypeColdMigration SchedulingEventType = "cold-migration" // SchedulingEventTypeEvacuation SchedulingEventType = "evacuation" SchedulingEventTypeResize SchedulingEventType = "resize" SchedulingEventTypeInitialPlacement SchedulingEventType = "initial-placement" )