报错信息如下:

org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dingTalkMessagePump' defined in file [F:\workspace\NEWSRC\WebContent\WEB-INF\classes\artifacts\ERP_Web_exploded\WEB-INF\classes\com\xxx\softprojectmanage\utils\DingTalkMessagePump.class]: Initialization of bean failed; nested exception is java.lang.IllegalStateException: Encountered invalid @Scheduled method 'gzyqtjList': For input string: "2S"

错误代码

 /***
* 每周2-6早上上班前(08:00)统计任务有延期的员工,并发送通知
*/
@Scheduled(cron = "0 0 8 ? * TUES-SAT")
public void gzyqtjList() {

正确代码

 /***
* 每周2-6早上上班前(08:00)统计任务有延期的员工,并发送通知
*/
@Scheduled(cron = "0 0 8 ? * TUE-SAT")
public void gzyqtjList() {

周二用TUE而不是TUES

Spring Scheduled定时任务报错 java.lang.IllegalStateException: Encountered invalid @Scheduled method 'xxx': For input string: "2S"的更多相关文章

  1. Spring Boot单元测试报错java.lang.IllegalStateException: Could not load TestContextBootstrapper [null]

    1 报错描述 java.lang.IllegalStateException: Could not load TestContextBootstrapper [null]. Specify @Boot ...

  2. 云笔记项目- 上传文件报错"java.lang.IllegalStateException: File has been moved - cannot be read again"

    在做文件上传时,当写入上传的文件到文件时,会报错“java.lang.IllegalStateException: File has been moved - cannot be read again ...

  3. eclipse启动报错java.lang.IllegalStateException: LifecycleProcessor not initialized - call 'refresh' befo

    报错: java.lang.IllegalStateException: LifecycleProcessor not initialized - call 'refresh' before invo ...

  4. 解决spring boot启动报错java.lang.NoClassDefFoundError: ch/qos/logback/classic/Level

    解决spring boot启动报错java.lang.NoClassDefFoundError: ch/qos/logback/classic/Level 学习了:https://blog.csdn. ...

  5. springboot测试启动报错java.lang.IllegalStateException: Unable to find a @SpringBootConfiguration, you need to use @ContextConfiguration or @SpringBootTest(classes=...) with your test

    springboot测试启动报错: java.lang.IllegalStateException: Unable to find a @SpringBootConfiguration, you ne ...

  6. spring mvc处理http请求报错:java.lang.IllegalStateException: getInputStream() has already been called for this request

    发送post请求到controller处理失败,报错日志如下: java.lang.IllegalStateException: getInputStream() has already been c ...

  7. springboot 启动报错 java.lang.IllegalStateException: Failed to introspect annotated methods on class org

    . ____ _ __ _ _ /\\ / ___'_ __ _ _(_)_ __ __ _ \ \ \ \ ( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \ \\/ ...

  8. spring低版本报错:java.lang.IllegalStateException: Context namespace element ‘annotation-config’ and its parser class [*] are only available on

    参考来源:http://blog.csdn.net/sunxiaoyu94/article/details/50492083 使用spring低版本(2.5.6),使用jre 8发现错误: Unexp ...

  9. Idea 的Test测试报错:java.lang.IllegalStateException: Failed to load ApplicationContext

    因为在Test里面使用了注解@Autowired 引入来至bean.xml文件的内容 ,而在Test没有没有办法自动引入,需要在Test类上加上注解 @ContextConfiguration(loc ...

随机推荐

  1. Spring boot 的 properties 属性值配置 application.properties 与 自定义properties

    配置属性值application.properties 文件直接配置: com.ieen.super.name="MDD" 自定义properties文件配置:src/main/r ...

  2. 好用的treeGrid

    jquery easyui 官网:http://www.jeasyui.net/plugins/186.html  下面以学校班级情况,先贴出效果图吧! 数据库设计:红色框中为必须要有的列,右边三个为 ...

  3. 同一台PC,配置多个同一存储平台下的Git账号【两个码云账号,配置在同一台PC上】

    问题:配置完 SSH Key, 使用[http地址]拉取代码异常.报一些没有权限的问题. 原因:配置多个gitee账号(码云)后.拉取代码时,应使用~.ssh/config中Host地址,而不是码云给 ...

  4. RNN探索(2)之手写数字识别

    这篇博文不介绍基础的RNN理论知识,只是初步探索如何使用Tensorflow,之后会用笔推导RNN的公式和理论,现在时间紧迫所以先使用为主~~ import numpy as np import te ...

  5. Monggodb基础

    MongoDB 查询文档使用 find() 方法. find() 方法以非结构化的方式来显示所有文档. 语法 MongoDB 查询数据的语法格式如下: db.collection.find(query ...

  6. ADB抓取内存命令

    1. 在IDE中查看Log信息当程序运行垃圾回收的时候,会打印一条Log信息,其格式如下:D/dalvikvm: <GC_Reason> <Amount_freed>, < ...

  7. Intellij IDEA常用快捷键介绍 Intellij IDEA快捷键大全汇总

    其他的快捷键还有很多,象Ctrl+G(跳转到指定行).Ctrl+F4(关闭当前编辑页面).Ctrl+F(搜索)等等,这些快捷键由于是各个编辑器都会提供的,而且定义的键位也都差不多,就没什么可说的了: ...

  8. python回归分析

    假设原函数由一个三角函数和一个线性项组成 import numpy as np import matplotlib.pyplot as plt %matplotlib inline def f(x): ...

  9. Grafana短信报警实现

    1.阿里云短信服务API2.Jenkins-plugin:Generic Webhook Trigger Plugin 阿里云 下载阿里云短信服务SDK 创建短信服务ACCESS_KEY_ID Gra ...

  10. 二叉搜索树的第K大节点

    题目描述 给定一颗二叉搜索树,请找出其中的第k大的结点. 分析 对二叉搜索树进行逆向中序遍历(先右再左),则遍历序列是降序排序的,因此中序遍历一颗二叉搜索树,可以很容易的得到它的第k大的节点.使用一个 ...