日期:2014-05-17  浏览次数:20802 次

关于Spring配置文件的问题
我是新手,在做实现增删改查的功能的模块,spring文件有问题,大家帮看看,小女感激不尽!
applicationContext.xml
Java code
<beans
    xmlns="http://www.springframework.org/schema/beans"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd">
    
    <bean id="UserUpdateInterceptor"
        class="com.hollycrm.hollyv8.zsptest.zsp.service.UserUpdateInterceptor" />
        
    <bean id="zsptest"
        class="org.springframework.aop.framework.ProxyFactoryBean">
    </bean>
    
    <bean id="UserManagerDao" class="com.experiment.Dao.DapImpl.UserManagerDaoImpl">
        <property name="zsptest" ref ="zsptest"></property>       
    </bean>
        
    <bean id="UserManagerService" class="com.hollycrm.hollyv8.zsptest.zsp.service.impl.UserManagerServiceImpl">
       <property name="userManagerDao" value="UserManagerDao" ></property>
    </bean>        
</beans>

错误如下:
Java code
2012-4-12 9:48:30 org.apache.catalina.core.StandardContext listenerStart
严重: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'UserManagerDao' defined in class path resource [applicationContext-zsptest.xml]: Cannot resolve reference to bean 'zsptest' while setting bean property 'zsptest'; nested exception is org.springframework.beans.factory.BeanCurrentlyInCreationException: Error creating bean with name 'zsptest': org.springframework.beans.factory.FactoryBeanNotInitializedException: Cannot determine target class for proxy
    at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:275)
    at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:104)
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1245)
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1010)
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:472)
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory$1.run(AbstractAutowireCapableBeanFactory.java:409)
    at java.security.AccessController.doPrivileged(Native Method)
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:380)
    at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:264)
    at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
    at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:261)
    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(Abstra