What happened:
Use vcjob create job, then job running, then suspend/resume 3 times, the vcjob will directly failure
What you expected to happen:
vcjob can success resume
How to reproduce it (as minimally and precisely as possible):
Anything else we need to know?:
|
case v1alpha1.ResumeJobAction: |
|
return KillJob(as.job, PodRetainPhaseSoft, func(status *vcbatch.JobStatus) bool { |
|
status.State.Phase = vcbatch.Restarting |
|
status.RetryCount++ |
|
return true |
|
}) |
|
// Get the maximum number of retries. |
|
maxRetry := ps.job.Job.Spec.MaxRetry |
|
|
|
if status.RetryCount >= maxRetry { |
|
// Failed is the phase that the job is restarted failed reached the maximum number of retries. |
|
status.State.Phase = vcbatch.Failed |
|
return true |
|
} |
when resume job, RetryCount++, and RetryCount >= maxRetry, job Failed
Environment:
- Volcano Version: v1.7
- Kubernetes version (use
kubectl version):
- Cloud provider or hardware configuration:
- OS (e.g. from /etc/os-release):
- Kernel (e.g.
uname -a):
- Install tools:
- Others:
What happened:
Use vcjob create job, then job running, then suspend/resume 3 times, the vcjob will directly failure
What you expected to happen:
vcjob can success resume
How to reproduce it (as minimally and precisely as possible):
Anything else we need to know?:
volcano/pkg/controllers/job/state/aborted.go
Lines 31 to 36 in 36abf1b
volcano/pkg/controllers/job/state/restarting.go
Lines 31 to 38 in 36abf1b
when resume job, RetryCount++, and RetryCount >= maxRetry, job Failed
Environment:
kubectl version):uname -a):