Unverified Commit bc343319 authored by Steven Zou's avatar Steven Zou Committed by GitHub
Browse files

Merge pull request #12906 from steven-zou/fix/preheat-job

fix(preheat):handle fail case of preheat in job
parents 560eba7b d4108e3f
......@@ -185,9 +185,15 @@ func (j *Job) Run(ctx job.Context, params job.Parameters) error {
myLogger.Infof("Check preheat progress: %s", s)
// Finished
if s.Status == provider.PreheatingStatusSuccess {
switch s.Status {
case provider.PreheatingStatusFail:
// Fail
return preheatJobRunningError(errors.Errorf("preheat failed: %s", s))
case provider.PreheatingStatusSuccess:
// Finished
return nil
// do nothing, check again
if shouldStop() {
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment