Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener org.springframework.beans.factory.BeanCreationException:
2016-08-10 22:35
656 查看
严重: 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 'daoSupport': Injection of resource dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlSessionTemplate' defined in class path resource [spring/ApplicationContext.xml]: Cannot resolve reference to bean 'sqlSessionFactory' while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlSessionFactory' defined in class path resource [spring/ApplicationContext.xml]: Invocation of init method failed;
时常报这个错误,时好时坏,经常重启计算机或清理工程更新maven就会好,但是有时候遇到还是非常苦恼,一弄就是浪费好几个小时,今天终于找到问题的根源,希望大家在遇到这个问题的时候,能够对你们有些许帮助
工程-->右键-->build path --->configue build path-->Java Build Path
--->Libraries--->Remove
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'daoSupport': Injection of resource dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlSessionTemplate' defined in class path resource [spring/ApplicationContext.xml]: Cannot resolve reference to bean 'sqlSessionFactory' while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlSessionFactory' defined in class path resource [spring/ApplicationContext.xml]: Invocation of init method failed;
时常报这个错误,时好时坏,经常重启计算机或清理工程更新maven就会好,但是有时候遇到还是非常苦恼,一弄就是浪费好几个小时,今天终于找到问题的根源,希望大家在遇到这个问题的时候,能够对你们有些许帮助
问题原因:由于Spring中的“asm-2.2.3.jar”和Hibernate中的“asm.jar”包冲突。解决办法是移除Spring2.0 AOP Libraries中的“asm-2.2.3.jar”即可
工程-->右键-->build path --->configue build path-->Java Build Path
--->Libraries--->Remove
相关文章推荐
- Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
- 严重: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListe
- [key]严重: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener(Spring配置异常)
- 错误:Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
- Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
- Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
- Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener. ...nested exception is java.lang.NoSuchMethodError:
- Exception sending context initialized event to listener instance of class org.springframework.web.co
- Exception sending context initialized event to listener instance of class org.springframework.web.c
- Exception sending context initialized event to listener instance of class org.springframework.web.co
- Exception sending context initialized event to listener instance of class org.springframework.web.co
- Exception sending context initialized event to listener instance of class org.springframework.web.co
- Exception sending context initialized event to listener instance of class org.springframework.web.co
- Exception sending context initialized event to listener instance of class org.springframework.web.co
- Exception sending context initialized event to listener instance of class org.springframework.web.ut
- Exception sending context initialized event to listener instance of class org.springframework.web.co
- Exception sending context initialized event to listener instance of class org.springframework.web.co
- 重: Exception sending context initialized event to listener instance of class org.springframework.web
- Exception sending context initialized event to listener instance of class org.springframework.web.co
- Exception sending context initialized event to listener instance of class org.springframework.web.co