郑鹏川
2021-01-18 17:03明明是设置的下午5点半的定时任务,2点半的时候就执行了。
@EnableScheduling @Component public class WorkNumReportSchedule { @Autowired private WorkTaskReportDetailService workTaskReportDetailService; // 工作日的17点半统计报工时间发送报工提醒消息 @Scheduled(cron = "0 30 17 * * ?") public void scheduleWorkingHoursStatistics() throws Exception { workTaskReportDetailService.encapsulationMessageEntity(DateUtil.formatDate(new Date(), "yyyy-MM-dd")); } }
明明是设置的下午5点半的定时任务,2点半的时候就执行了。
- 点赞
- 回答
- 收藏
- 复制链接分享
4条回答
为你推荐
- spring cron配置每天上午10点,下午2点半定时的定时任务怎么配?
- it技术
- 互联网问答
- IT行业问题
- 计算机技术
- 编程语言问答
- 0个回答
- Quartz CronTrigger定时疑问,求帮忙
- quartz
- 0个回答
- 定义每天 8:00 9:10 10:20 11:30触发的cron表达式的问题
- 企业应用
- 0个回答
- spring定时配置每天下午四点半和五点各执行一次咋弄?
- spring
- 7个回答