|
|
@ -222,17 +222,17 @@ public class JobScheduleHelper { |
|
|
|
@Override |
|
|
|
@Override |
|
|
|
public void run() { |
|
|
|
public void run() { |
|
|
|
|
|
|
|
|
|
|
|
// align second
|
|
|
|
|
|
|
|
try { |
|
|
|
|
|
|
|
TimeUnit.MILLISECONDS.sleep(1000 - System.currentTimeMillis()%1000 ); |
|
|
|
|
|
|
|
} catch (InterruptedException e) { |
|
|
|
|
|
|
|
if (!ringThreadToStop) { |
|
|
|
|
|
|
|
logger.error(e.getMessage(), e); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
while (!ringThreadToStop) { |
|
|
|
while (!ringThreadToStop) { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// align second
|
|
|
|
|
|
|
|
try { |
|
|
|
|
|
|
|
TimeUnit.MILLISECONDS.sleep(1000 - System.currentTimeMillis() % 1000); |
|
|
|
|
|
|
|
} catch (InterruptedException e) { |
|
|
|
|
|
|
|
if (!ringThreadToStop) { |
|
|
|
|
|
|
|
logger.error(e.getMessage(), e); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
try { |
|
|
|
try { |
|
|
|
// second data
|
|
|
|
// second data
|
|
|
|
List<Integer> ringItemData = new ArrayList<>(); |
|
|
|
List<Integer> ringItemData = new ArrayList<>(); |
|
|
@ -260,15 +260,6 @@ public class JobScheduleHelper { |
|
|
|
logger.error(">>>>>>>>>>> xxl-job, JobScheduleHelper#ringThread error:{}", e); |
|
|
|
logger.error(">>>>>>>>>>> xxl-job, JobScheduleHelper#ringThread error:{}", e); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// next second, align second
|
|
|
|
|
|
|
|
try { |
|
|
|
|
|
|
|
TimeUnit.MILLISECONDS.sleep(1000 - System.currentTimeMillis()%1000); |
|
|
|
|
|
|
|
} catch (InterruptedException e) { |
|
|
|
|
|
|
|
if (!ringThreadToStop) { |
|
|
|
|
|
|
|
logger.error(e.getMessage(), e); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
logger.info(">>>>>>>>>>> xxl-job, JobScheduleHelper#ringThread stop"); |
|
|
|
logger.info(">>>>>>>>>>> xxl-job, JobScheduleHelper#ringThread stop"); |
|
|
|
} |
|
|
|
} |
|
|
|