fix job launch deadlock

* This both fixes the deadlock problem and a logic problem. We shouldn't
set the job's job_template current_job to pending jobs.
This commit is contained in:
Chris Meyers
2017-07-10 10:34:36 -04:00
committed by Matthew Jones
parent 459c33d272
commit 7a795b8681
+1 -1
View File
@@ -713,7 +713,7 @@ class UnifiedJob(PolymorphicModel, PasswordFieldsModel, CommonModelNameNotUnique
result = super(UnifiedJob, self).save(*args, **kwargs) result = super(UnifiedJob, self).save(*args, **kwargs)
# If status changed, update the parent instance. # If status changed, update the parent instance.
if self.status != status_before: if self.status != status_before and self.status != 'pending':
self._update_parent_instance() self._update_parent_instance()
# Done. # Done.