Commit d35bc023 by xyyz150

优化在JobThread尝试30次后销毁任务时,并发插入到triggerQueue中任务会失败的场景

parent 4dabb4b1
...@@ -165,7 +165,9 @@ public class JobThread extends Thread{ ...@@ -165,7 +165,9 @@ public class JobThread extends Thread{
} else { } else {
if (idleTimes > 30) { if (idleTimes > 30) {
XxlJobExecutor.removeJobThread(jobId, "excutor idel times over limit."); if(triggerQueue ==null||triggerQueue.size()==0) {
XxlJobExecutor.removeJobThread(jobId, "excutor idel times over limit.");
}
} }
} }
} catch (Throwable e) { } catch (Throwable e) {
......
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 sign in to comment