关于Failed to convert property value of type [org.quartz.impl.StdScheduler] to required type [org.springframework.scheduling.quartz.SchedulerFactoryBean
在一个业务类有下列属性
private SchedulerFactoryBeanscheduler;
public SchedulerFactory BeangetScheduler() {
return scheduler;
}
public void setScheduler(SchedulerFactoryBean scheduler) {
this.scheduler = scheduler;
}
用spring 进行装配:
<property name="scheduler">
<ref bean="schedulerFactoryBean" />
</property> </bean>
<bean id="schedulerFactoryBean" class="org.springframework.scheduling.quartz.SchedulerFactoryBean"/>
启动时候报:Failed to convert property value of type [org.quartz.impl.StdScheduler] to required type [org.springframework.scheduling.quartz.SchedulerFactoryBean异常
解决方案:
SchedulerFactoryBean 这个bean
<bean id="Scheduler" lazy-init="false" autowire="no"
class="org.springframework.scheduling.quartz.SchedulerFactoryBean" >
</bean>
它是一个工厂bean,得到的不是它本身,而是它负责创建的org.quartz.impl.StdScheduler对象 ,
所以属性需要修改:
private StdScheduler scheduler;
public StdScheduler getScheduler() {
return scheduler;
}
public void setScheduler(StdScheduler scheduler) {
this.scheduler = scheduler;
}
关于Failed to convert property value of type [org.quartz.impl.StdScheduler] to required type [org.springframework.scheduling.quartz.SchedulerFactoryBean的更多相关文章
- Spring 整合 Flex (BlazeDS)无法从as对象 到 Java对象转换的异常:org.springframework.beans.ConversionNotSupportedException: Failed to convert property value of type 'java.util.Date' to required type 'java.sql.Timestamp' for property 'wfsj'; nested exception is java.lang.Ill
异常信息如下: org.springframework.beans.ConversionNotSupportedException: Failed to convert property value ...
- spring mvc出现 Failed to convert property value of type 'java.lang.String' to required type 'java.util.Date' for property 'endtime'
在使用spring mvc中,绑定页面传递时间字符串数据给Date类型是出错: Failed to convert property value of type [java.lang.String] ...
- 出错:Failed to convert property value of type 'org.apache.ibatis.session.defaults.DefaultSqlSessionFactory' to required type 'java.lang.String' for property 'sqlSessionFactoryBeanName';
出错的详细信息: 3 ERROR [http-nio-80-exec-3] org.springframework.web.servlet.DispatcherServlet - Context in ...
- org.springframework.beans.TypeMismatchException: Failed to convert property value of type 'null' to required type 'double' for property 'band'; nested exception is org.springframework.core.convert.Con
本文为博主原创,未经允许不得转载: 先将异常粘贴出来: 20:37:26,909 ERROR [com.suning.fucdn.controller.ProductDataStaticsContro ...
- 【spring mvc】后台API查询接口,get请求,后台Date字段接收前台String类型的时间,报错default message [Failed to convert property value of type 'java.lang.String' to required type 'java.util.Date' for property 'createDate';
后台API查询接口,get请求,后台Date字段接收前台String类型的时间筛选条件 后台接口接收 使用的实体 而createDate字段在后台实体中是Date类型 报错信息: org.spring ...
- Java 异常 Failed to convert property value of type 'java.lang.String' to required type 'java.util.Date'
查询时发送给服务器的日期的字符串格式:yyyy-MM-dd HH:mm:ss 服务器接收到日期的字符串之后,向 MySQL 数据库发起查询时,因为没有指定日期时间格式,导致字符串数据不能正确地转换为日 ...
- [Failed to convert property value of type 'java.lang.String' to required type 'java.util.Date' for property 'beginTime';
依照https://stackoverflow.com/questions/23702041/failed-to-convert-property-value-of-type-java-lang-st ...
- Failed to convert property value of type 'java.util.LinkedHashMap' to required type 'java.util.Map' for property 'filters'
在使用shiro的自定义filter出现的问题 <property name="filters"> <util:map> <entry key=&qu ...
- Failed to convert property value of type 'java.lang.String' to required type 'java.util.Date'
我的情况是:在applicationContext.xml文件中配置 <bean id="member" class="com.entity.Member" ...
随机推荐
- 什么是CS和BS结构,两种结构的区别
什么是CS和BS结构,两种结构的区别 什么是C/S和B/S结构? C/S又称Client/Server或客户/服务器模式.服务器通常采用高性能的PC.工作站或小型机,并采用大型数据库系 ...
- Google搜索技术
命令 双引号 把搜索词放在双引号中,代表完全匹配搜索,也就是说搜索结果返回的页面包含双引号中出现的所有的词,连顺序也必须完全匹配.bd和Google都支持这个指令. 减号 减号代表搜索不包含减号后面的 ...
- 月半小夜曲下的畅想--DOCTYPE模式
月半小夜曲下的畅想--DOCTYPE模式 @(css3 box-sizing)[doctype声明|quirks模式|妙瞳] DOCTYPE文档类型标签,该标签是将特定的标准通用标记语言或者XML文档 ...
- mysql 5.5 win7安装最后一步总是停止响应
今天刚开始安装了64位版本的mysql5.5 ,安装很顺利,后来发现库不兼容的问题,于是卸载,安装mysql-5.5.27-win32的32位版本,奇怪了,怎么安装,怎么卸载都不行,就是到最 后一步停 ...
- Ceph Newstore存储引擎介绍
在Ceph被越来越多地应用于各项存储业务过程中,其性能及调优策略也成为用户密切关注讨论的话题,影响性能表现关键因素之一即OSD存储引擎实现:Ceph基础组件RADOS是强一致.对象存储系统,其OSD底 ...
- MySQL高可用解决方案(MySQL HA Solution)
http://blog.sina.com.cn/s/blog_7e89c3f501012vtr.html 什么是高可用性?很多公司的服务都是24小时*365天不间断的.比如Call Center.这就 ...
- Oracle笔记(三)单行函数
-函数 函数像一个黑盒子一样(看不到里边的构造),有参数返回值,可以为我们完成一定的功能. -单行 这种函数会对结果中的每一行计算一次,每行返回一个结果,单行概念区别于分组函数. 单行函数主要分为以下 ...
- WebService简单介绍
什么是Web Services 一直没有一个明确的答案,最近听了一个大牛讲WebService,顿时明了了,作个记录免得以后忘了. N年之前,各公司都在炒作SOA,不过现在已经没人再提了,现在都改叫W ...
- iOS Core Animation学习总结(3)--动画的基本类型
一. CABasicAnimation (基础动画) 移位: CABasicAnimation *animation = [CABasicAnimation animation]; //keyPath ...
- 理解css 中的position五个属性
在实际开发页面布局时,运用position,对定位的块级元素的嵌套的效果总是不太理解,这里做了几个测试 一般的在w3c中我们可以很容易的获取定义: static : 默认值.没有定位,元素出现在正常的 ...