当我使用 spring 配置启动服务器时遇到问题。我将 spring 与 Zk 一起使用
当我使用 spring 配置启动服务器时遇到问题。我遇到以下错误
我正在将 spring 与 Zk 一起使用,并且我使用 zkspring-core 3.0RC
错误:org.springframework.web.context.ContextLoader - 上下文初始化失败 org.springframework.beans.factory.BeanCreationException:创建名为“zkTypePropertyEditor”的bean时出错:bean初始化失败;嵌套异常是 org.springframework.beans.ConversionNotSupportedException:无法将类型“java.util.HashMap”的属性值转换为属性“customEditors”所需的类型“java.util.Map”;嵌套异常是 java.lang.IllegalStateException:无法将属性“customEditors[class java.lang.Class]”的类型 [java.lang.Class] 的值转换为所需类型 [java.lang.String]:没有匹配的编辑器或转换找到策略 在 org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:527) ...
谢谢
I am facing a problem when i startup the server with spring configuration. I have got the Following Error
I am using spring with Zk and I use zkspring-core 3.0RC
ERROR: org.springframework.web.context.ContextLoader - Context initialization failed
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'zkTypePropertyEditor': Initialization of bean failed; nested exception is org.springframework.beans.ConversionNotSupportedException: Failed to convert property value of type 'java.util.HashMap' to required type 'java.util.Map' for property 'customEditors'; nested exception is java.lang.IllegalStateException: Cannot convert value of type [java.lang.Class] to required type [java.lang.String] for property 'customEditors[class java.lang.Class]': no matching editors or conversion strategy found
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:527)
...
thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
这是 ZK Spring 3.0 RC 中的一个已知错误:
http ://code.google.com/p/zkspring/issues/detail?id=3&can=1
它已经修复了。您可以下载最新版本(8 月 10 日版本)来试用:
http:// code.google.com/p/zkspring/downloads/list
Henri Chen
ZK团队
http://www.zkoss.org
This is a known bug in ZK Spring 3.0 RC:
http://code.google.com/p/zkspring/issues/detail?id=3&can=1
It is already fixed. You can download the freshly version (Aug. 10 version) to try it:
http://code.google.com/p/zkspring/downloads/list
Henri Chen
The ZK Team
http://www.zkoss.org
我们在使用 Apache CXF 2.7.4 的 Spring 3.1.0-RELEASE 中遇到了同样的问题:
org.springframework.beans.factory.BeanCreationException:创建类路径资源中定义的名为“Contact”的 bean 时出错 [DoMappings/EAI/do-contact -mapping.xml]:bean初始化失败;嵌套异常是 org.springframework.beans.ConversionNotSupportedException:无法将类型“java.util.LinkedHashMap”的属性值转换为属性“doFieldNameToDsFieldNameMap”所需的类型“java.util.Map”;嵌套异常是 java.lang.IllegalStateException:无法将属性“doFieldNameToDsFieldNameMap [name]”的类型 [java.lang.String] 的值转换为所需类型 [java.util.Map]:找不到匹配的编辑器或转换
策略切换到 Spring 3.1.1-RELEASE 来解决该问题。
We had the same problem with Spring 3.1.0-RELEASE with Apache CXF 2.7.4:
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'Contact' defined in class path resource [DoMappings/EAI/do-contact-mapping.xml]: Initialization of bean failed; nested exception is org.springframework.beans.ConversionNotSupportedException: Failed to convert property value of type 'java.util.LinkedHashMap' to required type 'java.util.Map' for property 'doFieldNameToDsFieldNameMap'; nested exception is java.lang.IllegalStateException: Cannot convert value of type [java.lang.String] to required type [java.util.Map] for property 'doFieldNameToDsFieldNameMap[name]': no matching editors or conversion strategy found
We had to switch to Spring 3.1.1-RELEASE to fix the issue.