org.springframework.beans.factory.BeanCreationException
2010-05-02 10:31
337 查看
严重: Context initialization failed org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'userChoiService' defined in file [C:/tomcat6.0/webapps/Reservationsystem2/WEB-INF/classes/applicationContext-beans.xml]: Invocation of init method failed; nested exception is java.lang.IllegalArgumentException: sessionFactory or hibernateTemplate is required Caused by: java.lang.IllegalArgumentException: sessionFactory or hibernateTemplate is required at org.springframework.orm.hibernate3.support.HibernateDaoSupport.checkDaoConfig(HibernateDaoSupport.java:112) at org.springframework.dao.support.DaoSupport.afterPropertiesSet(DaoSupport.java:44) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1062) 原因:在写userchoiserviceimpl时由于是复制Dao包下的文件,所以很粗心的把extends HibernateDaoSupport 也copy过去了修改方法:1去掉、extends HibernateDaoSupport 就可以了; 2、 在bean里加入(这个没试过)。
相关文章推荐
- org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFacto
- org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'powerAction'
- org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'u' defined i
- org.springframework.beans.factory.BeanCreationException
- org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'selectcommoninfo' defined in ServletCont
- org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'UserDao' def
- 个人笔记 org.springframework.beans.factory.BeanCreationException: Could not autowire field: private com.
- org.springframework.beans.factory.BeanCreationException;Caused by: org.springframework.beans.factory
- 解决org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.spring
- org.springframework.beans.factory.BeanCreationException: Error creating bean with name
- org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'objectMapper
- org.springframework.beans.factory.BeanCreationException
- org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'userServic
- tomcat启动报错:org.springframework.beans.factory.BeanCreationException
- Exception in thread "main" org.springframework.beans.factory.BeanCreationException: Error creating b
- org.springframework.beans.factory.BeanCreationException(spring注入问题)
- org.springframework.beans.factory.BeanCreationException
- 报错解决Context initialization failed org.springframework.beans.factory.BeanCreationException
- org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlSessionFa
- spring-AOP编程出现org.springframework.beans.factory.BeanCreationException