tomcat上跑起来的时候控制台显示这个错误,大神们能帮我看看这是什么错么。。。。。
weixin:liboxing940721,希望可以互相沟通下,刚入门的小菜鸟
2018-6-20 16:52:18 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 'httpAllVPay': Injection of resource dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'allVPayServiceImpl': Injection of resource dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'databaseService' defined in class path resource [spring/spring-impl.xml]: Cannot resolve reference to bean 'allVPayDao' while setting bean property 'allvpayDao'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'allVPayDao' defined in file [F:\workspcae\apache-tomcat-7.0.88\wtpwebapps\allvpay-web\WEB-INF\classes\com\efuture\allvpay\dao\AllVPayDao.class]: Unsatisfied dependency expressed through bean property 'sqlSessionFactory': : Error creating bean with name 'sqlSessionFactory' defined in class path resource [spring/spring-dbsource.xml]: Cannot resolve reference to bean 'dataSource' while setting bean property 'dataSource'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [spring/spring-dbsource.xml]: Invocation of init method failed; nested exception is javax.naming.NameNotFoundException: Name [jdbc/mssql-allvpay] is not bound in this Context. Unable to find [jdbc].; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlSessionFactory' defined in class path resource [spring/spring-dbsource.xml]: Cannot resolve reference to bean 'dataSource' while setting bean property 'dataSource'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [spring/spring-dbsource.xml]: Invocation of init method failed; nested exception is javax.naming.NameNotFoundException: Name [jdbc/mssql-allvpay] is not bound in this Context. Unable to find [jdbc].
Related cause: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [spring/spring-dbsource.xml]: Invocation of init method failed; nested exception is javax.naming.NameNotFoundException: Name [jdbc/mssql-allvpay] is not bound in this Context. Unable to find [jdbc].
Related cause: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [spring/spring-dbsource.xml]: Invocation of init method failed; nested exception is javax.naming.NameNotFoundException: Name [jdbc/mssql-allvpay] is not bound in this Context. Unable to find [jdbc].
Related cause: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'allVPayDao' defined in file [F:\workspcae\apache-tomcat-7.0.88\wtpwebapps\allvpay-web\WEB-INF\classes\com\efuture\allvpay\dao\AllVPayDao.class]: Unsatisfied dependency expressed through bean property 'sqlSessionFactory': : Error creating bean with name 'sqlSessionFactory' defined in class path resource [spring/spring-dbsource.xml]: Cannot resolve reference to bean 'dataSource' while setting bean property 'dataSource'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [spring/spring-dbsource.xml]: Invocation of init method failed; nested exception is javax.naming.NameNotFoundException: Name [jdbc/mssql-allvpay] is not bound in this Context. Unable to find [jdbc].; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlSessionFactory' defined in class path resource [spring/spring-dbsource.xml]: Cannot resolve reference to bean 'dataSource' while setting bean property 'dataSource'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [spring/spring-dbsource.xml]: Invocation of init method failed; nested exception is javax.naming.NameNotFoundException: Name [jdbc/mssql-allvpay] is not bound in this Context. Unable to find [jdbc].
Related cause: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [spring/spring-dbsource.xml]: Invocation of init method failed; nested exception is javax.naming.NameNotFoundException: Name [jdbc/mssql-allvpay] is not bound in this Context. Unable to find [jdbc].
Related cause: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'allVPayDao' defined in file [F:\workspcae\apache-tomcat-7.0.88\wtpwebapps\allvpay-web\WEB-INF\classes\com\efuture\allvpay\dao\AllVPayDao.class]: Unsatisfied dependency expressed through bean property 'sqlSessionFactory': : Error creating bean with name 'sqlSessionFactory' defined in class path resource [spring/spring-dbsource.xml]: Cannot resolve reference to bean 'dataSource' while setting bean property 'dataSource'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [spring/spring-dbsource.xml]: Invocation of init method failed; nested exception is javax.naming.NameNotFoundException: Name [jdbc/mssql-allvpay] is not bound in this Context. Unable to find [jdbc].; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlSessionFactory' defined in class path resource [spring/spring-dbsource.xml]: Cannot resolve reference to bean 'dataSource' while setting bean property 'dataSource'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [spring/spring-dbsource.xml]: Invocation of init method failed; nested exception is javax.naming.NameNotFoundException: Name [jdbc/mssql-allvpay] is not bound in this Context. Unable to find [jdbc].
web.xml查找监听的类,AllVPayDao.java报错了看下是什么原因
看你这么多Error creating bean with name xxx的错误,应该是你spring的配置有问题。或者缺包,路径放错了等等。
创建名称为 "httpAllVPay" 的 bean 时出错: 资源依赖项的注入失败。
1 web.xml是对有找到对应文件
2 jar包缺少