你是否正在寻找关于schedulerfactorybean的内容?让我把最简洁的东西奉献给你:
今天在做Spring Quarter动态设置触发时间时,需要在Service中注入org.springframework.scheduling.quartz.schedulerfactorybean使用下面的代码可用:
localQuartzScheduler通过注解注入
@Resource
private schedulerfactorybean localQuartzScheduler
Java代码
启动tomcat报以下错误:
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'addJob' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Initialization of bean failed; nested exception is org.springframework.beans.TypeMismatchException: Failed to convert property value of type [org.quartz.impl.StdScheduler] to required type [org.springframework.scheduling.quartz.SchedulerFactoryBean] for property 'scheduler'; nested exception is java.lang.IllegalArgumentException: Cannot convert value of type [org.quartz.impl.StdScheduler] to required type [org.springframework.scheduling.quartz.schedulerfactorybean] for property 'scheduler': no matching editors or conversion strategy found
大致错误意思为类型不匹配,。
上网查了一下
以上就是关于schedulerfactorybean的全部内容,相信你一定会非常满意。
本文来自电脑杂谈,转载请注明本文网址:
http://www.pc-fly.com/a/jisuanjixue/article-3463-1.html
以战应战才能避免战争