WARN - Configurator.configure(126) | No configuration found. Configuring ehcache from ehcache-failsafe.xml found in the classpath: jar:file:/D:/apache-tomcat-5.5.23/webapps/csm/WEB-INF/lib/ehcache-1.1.jar!/ehcache-failsafe.xml
INFO - SessionFactoryObjectFactory.addInstance(82) | Not binding factory to JNDI, no JNDI name configured
INFO - SessionFactoryImpl.close(729) | closing
ERROR - ContextLoader.initWebApplicationContext(211) | Context initialization failed
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'jiuzhenBOTarget' defined in ServletContext resource [/WEB-INF/classes/com/cmp/yiwu/qkzl/spring-qkzl.xml]: Initialization of bean failed; nested exception is 
ERROR - ApplicationContext.log(676) | StandardWrapper.Throwable
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'jiuzhenBOTarget' defined in ServletContext resource [/WEB-INF/classes/com/cmp/yiwu/qkzl/spring-qkzl.xml]: Initialization of bean failed; nested exception is 
2007-10-3 9:36:25 org.apache.catalina.loader.WebappClassLoader validateJarFile
信息: validateJarFile(D:\apache-tomcat-5.5.23\webapps\csm.myeclipse.bak\WEB-INF\lib\servlet.jar) - jar not loaded. See Servlet Spec 2.3, section 9.7.2. Offending class: javax/servlet/Servlet.class============================================================================================================================错误信息如上了,我第一个dao注入没有问题的,就是到了第二个的时候,出现这种错误,求大虾们给以正解....

解决方案 »

  1.   

    是不是你spring的配置文件那些属性的大小不一致
      

  2.   

    【jsf+spring+hibernate异常】Spring:启动时报错Context initialization failed从日志信息看问题已经很明显了,是applicationContext.xml的dataSource 问题。

    <bean id="dataSource" class="org.apache.commons.dbcp.BasicDataSource">
    改为
    <bean id="dataSource"class="org.springframework.jdbc.datasource.DriverManagerDataSource">
    <!--[if !supportEmptyParas]-->之后问题得到解决。 <!--[endif]-->       出现"Error listenerStart"一般是applicationContext.xml中的bean加载有问题。在用eclipse做webwork + spring + hibernate 的项目时一般都是用Myeclipse自动生成那些配置文件,而有些相关的jar<!--[if !supportEmptyParas]-->或者文件并没有加载在至项目中,以至引出奇怪的问题,又因为是自动生成的东西所以往往会忽略一些文件,而问题确恰恰是这些生成的文件所致,所以自动化的东西也未必一定是正确的 org.springframework.jdbc.datasource.DriverManagerDataSource 不可以使用连接池。org.apache.commons.dbcp.BasicDataSource作为注入的DataSource源,为了使用 DBCP的功能,必须要将commons-dbcp.jar加入CLASSPATH中,另外还需要commons-pool.jar和commons- collections.jar,这些都可以在Spring的lib目录下找到。org.springframework.jdbc.datasource.DriverManagerDataSource并没有提供连接池的功能,只能作作简单的单机连接测试。
    使用org.apache.commons.dbcp.BasicDataSource时缺少commons-pool.jar所以会出现如题的问题