Documentation ¶
Overview ¶
Package v1alpha1 contains API Schema definitions for the bus v1alpha1 API group +kubebuilder:object:generate=true +groupName=bus.volcano.sh +k8s:deepcopy-gen=package
Index ¶
Constants ¶
const GroupName = "bus.volcano.sh"
GroupName is the group name used in this package.
Variables ¶
var ( // SchemeBuilder points to a list of functions added to Scheme. SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) // AddToScheme applies all the stored functions to the scheme. AddToScheme = SchemeBuilder.AddToScheme )
var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1alpha1"}
SchemeGroupVersion is the group version used to register these objects.
Functions ¶
func Resource ¶
func Resource(resource string) schema.GroupResource
Resource takes an unqualified resource and returns a Group-qualified GroupResource.
Types ¶
type Action ¶ added in v0.4.0
type Action string
Action is the action that Job controller will take according to the event.
const ( // AbortJobAction if this action is set, the whole job will be aborted: // all Pod of Job will be evicted, and no Pod will be recreated AbortJobAction Action = "AbortJob" // RestartJobAction if this action is set, the whole job will be restarted RestartJobAction Action = "RestartJob" // RestartTaskAction if this action is set, only the task will be restarted; default action. // This action can not work together with job level events, e.g. JobUnschedulable RestartTaskAction Action = "RestartTask" // TerminateJobAction if this action is set, the whole job wil be terminated // and can not be resumed: all Pod of Job will be evicted, and no Pod will be recreated. TerminateJobAction Action = "TerminateJob" // CompleteJobAction if this action is set, the unfinished pods will be killed, job completed. CompleteJobAction Action = "CompleteJob" // ResumeJobAction is the action to resume an aborted job. ResumeJobAction Action = "ResumeJob" // SyncJobAction is the action to sync Job/Pod status. SyncJobAction Action = "SyncJob" // EnqueueAction is the action to sync Job inqueue status. EnqueueAction Action = "EnqueueJob" // SyncQueueAction is the action to sync queue status. SyncQueueAction Action = "SyncQueue" // OpenQueueAction is the action to open queue OpenQueueAction Action = "OpenQueue" // CloseQueueAction is the action to close queue CloseQueueAction Action = "CloseQueue" )
type Command ¶
type Command struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Action defines the action that will be took to the target object. Action string `json:"action,omitempty" protobuf:"bytes,2,opt,name=action"` // TargetObject defines the target object of this command. TargetObject *metav1.OwnerReference `json:"target,omitempty" protobuf:"bytes,3,opt,name=target"` // Unique, one-word, CamelCase reason for this command. // +optional Reason string `json:"reason,omitempty" protobuf:"bytes,4,opt,name=reason"` // Human-readable message indicating details of this command. // +optional Message string `json:"message,omitempty" protobuf:"bytes,4,opt,name=message"` }
Command defines command structure.
func (*Command) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Command.
func (*Command) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Command) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type CommandList ¶
type CommandList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` Items []Command `json:"items" protobuf:"bytes,2,rep,name=items"` }
CommandList defines list of commands.
func (*CommandList) DeepCopy ¶
func (in *CommandList) DeepCopy() *CommandList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CommandList.
func (*CommandList) DeepCopyInto ¶
func (in *CommandList) DeepCopyInto(out *CommandList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*CommandList) DeepCopyObject ¶
func (in *CommandList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type Event ¶ added in v0.4.0
type Event string
Event represent the phase of Job, e.g. pod-failed.
const ( // AnyEvent means all event AnyEvent Event = "*" // PodFailedEvent is triggered if Pod was failed PodFailedEvent Event = "PodFailed" // PodEvictedEvent is triggered if Pod was deleted PodEvictedEvent Event = "PodEvicted" // JobUnknownEvent These below are several events can lead to job 'Unknown' // 1. Task Unschedulable, this is triggered when part of // pods can't be scheduled while some are already running in gang-scheduling case. JobUnknownEvent Event = "Unknown" // TaskCompletedEvent is triggered if the 'Replicas' amount of pods in one task are succeed TaskCompletedEvent Event = "TaskCompleted" // OutOfSyncEvent is triggered if Pod/Job is updated(add/update/delete) OutOfSyncEvent Event = "OutOfSync" // CommandIssuedEvent is triggered if a command is raised by user CommandIssuedEvent Event = "CommandIssued" // JobUpdatedEvent is triggered if Job is updated, currently only scale up/down JobUpdatedEvent Event = "JobUpdated" )