xuxueli / xxl-job

A distributed task scheduling framework.(分布式任务调度平台XXL-JOB)
http://www.xuxueli.com/xxl-job/
GNU General Public License v3.0
27.03k stars 10.75k forks source link

cron延迟8小时 #3104

Open hothotsavage opened 1 year ago

hothotsavage commented 1 year ago

Please answer some questions before submitting your issue. Thanks!

Which version of XXL-JOB do you using?

2.3.1

Expected behavior

cron定时执行

Actual behavior

延迟8小时才执行 mysql表xxl_job_info的trigger_next_time字段记录的时间比设定cron时间延迟8小时

Steps to reproduce the behavior

Other information

coderManFans commented 1 year ago

cron表达式有没有

hothotsavage commented 1 year ago
屏幕截图 2023-03-04 081154 屏幕截图 2023-03-04 081248

表中记录的下一次触发时间戳: xxl_job_info.triger_next_time = 1677974400000 (2023-03-05 08:00:00.000)

coderManFans commented 1 year ago

有没有查一下数据库连接的时区等配置。

1325075688gw commented 1 year ago

中国是东8区,刚好8小时,你这肯定是时区设置有问题

sudolxwh commented 1 year ago

这个是你的时区设置问题

XiaoyuWant commented 6 months ago

Please set app timezone before SpringApplication.run().

TimeZone timeZone = TimeZone.getTimeZone("Asia/Shanghai");
TimeZone.setDefault(timeZone);