setFail is an internal function to set the job to failed. This does not send the failedJob.
(f *proto.FailedJob)
| 300 | |
| 301 | // setFail is an internal function to set the job to failed. This does not send the failedJob. |
| 302 | func (r *Runner) setFail(f *proto.FailedJob) { |
| 303 | r.mutex.Lock() |
| 304 | defer r.mutex.Unlock() |
| 305 | if r.failedJob == nil { |
| 306 | f.JobId = r.job.JobId |
| 307 | r.failedJob = f |
| 308 | r.cond.Signal() |
| 309 | } |
| 310 | } |
| 311 | |
| 312 | // ForceStop signals all goroutines to stop and prevents any further API calls back to coder server for this job |
| 313 | func (r *Runner) ForceStop() { |
no test coverage detected