@@ -823,18 +823,13 @@ def _rescheduleFailedJob(self, jobID, message, direct=False):
823
823
824
824
self .log .warn ("Failure ==> rescheduling" , f"(during { message } )" )
825
825
826
- if direct :
827
- JobStateUpdateClient ().setJobStatus (
828
- int (jobID ), status = JobStatus .RESCHEDULED , applicationStatus = message , source = "JobAgent@%s" , force = True
829
- )
830
- else :
831
- originalJobID = self .jobReport .jobID
832
- self .jobReport .setJob (jobID )
833
- # Setting a job parameter does not help since the job will be rescheduled,
834
- # instead set the status with the cause and then another status showing the
835
- # reschedule operation.
836
- self .jobReport .setJobStatus (status = JobStatus .RESCHEDULED , applicationStatus = message , sendFlag = True )
837
- self .jobReport .setJob (originalJobID )
826
+ originalJobID = self .jobReport .jobID
827
+ self .jobReport .setJob (jobID )
828
+ # Setting a job parameter does not help since the job will be rescheduled,
829
+ # instead set the status with the cause and then another status showing the
830
+ # reschedule operation.
831
+ self .jobReport .setJobStatus (status = JobStatus .RESCHEDULED , applicationStatus = message , sendFlag = True )
832
+ self .jobReport .setJob (originalJobID )
838
833
839
834
self .log .info ("Job will be rescheduled" )
840
835
result = JobManagerClient ().rescheduleJob (jobID )
0 commit comments