Documentation ¶
Index ¶
Constants ¶
View Source
const DefaultMaxRetry int32 = 3
DefaultMaxRetry is the default number of retries.
Variables ¶
View Source
var ( // SyncJob will create or delete Pods according to Job's spec. SyncJob ActionFn // KillJob kill all Pods of Job with phase not in podRetainPhase. KillJob KillActionFn )
View Source
var PodRetainPhaseNone = PhaseMap{}
PodRetainPhaseNone stores no phase
View Source
var PodRetainPhaseSoft = PhaseMap{ v1.PodSucceeded: {}, v1.PodFailed: {}, }
PodRetainPhaseSoft stores PodSucceeded and PodFailed Phase
Functions ¶
func TotalTasks ¶
TotalTasks returns number of tasks in a given volcano job
Types ¶
type ActionFn ¶
type ActionFn func(job *apis.JobInfo, fn UpdateStatusFn) error
ActionFn will create or delete Pods according to Job's spec.
type KillActionFn ¶
type KillActionFn func(job *apis.JobInfo, podRetainPhase PhaseMap, fn UpdateStatusFn) error
KillActionFn kill all Pods of Job with phase not in podRetainPhase.
type State ¶
type State interface { // Execute executes the actions based on current state. Execute(act vcbatch.Action) error }
State interface
type UpdateStatusFn ¶
UpdateStatusFn updates the job status.
Click to show internal directories.
Click to hide internal directories.