我是新手,正在尝试创建一个 Spring5 MVC/Hibernate5 Web 应用程序,但是当我启动 Tomcat 时出现以下错误:
最初的问题与事务管理器有关,在添加事务管理器 bean 定义之前,应用程序启动正常但失败并显示错误消息,指出它无法创建事务线程。
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'customerController' defined in ServletContext resource [/WEB-INF/spring/store.xml]: Initialization of bean failed; nested exception is org.springframework.beans.ConversionNotSupportedException: Failed to convert property value of type 'com.sun.proxy.$Proxy210 implementing com.store.service.CustomerService,java.io.Serializable,org.springframework.aop.SpringProxy,org.springframework.aop.framework.Advised,org.springframework.core.DecoratingProxy' to required type 'com.store.service.CustomerServiceImpl' for property 'customerService'; nested exception is java.lang.IllegalStateException: Cannot convert value of type 'com.sun.proxy.$Proxy210 implementing com.store.service.CustomerService,java.io.Serializable,org.springframework.aop.SpringProxy,org.springframework.aop.framework.Advised,org.springframework.core.DecoratingProxy' to required type 'com.store.service.CustomerServiceImpl' for property 'customerService': no matching editors or conversion strategy found
我的 web.xml :
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
id="WebApp_ID" version="2.5">
</web-app>
aluckdog
相关分类