java 微博

lkrexe8 2016-03-28 10:03:55



web.xml代码如下
<?xml version="1.0" encoding="UTF-8"?>
<web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
<welcome-file-list>
<welcome-file>index.jsp</welcome-file>
</welcome-file-list>
<filter>
<filter-name>struts2</filter-name>
<filter-class>
org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter
</filter-class>
</filter>

<filter-mapping>
<filter-name>struts2</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>

<listener>
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
</listener>

</web-app>
...全文
289 9 打赏 收藏 转发到动态 举报
写回复
用AI写文章
9 条回复
切换为时间正序
请发表友善的回复…
发表回复
遥远的想念 2016-03-29
  • 打赏
  • 举报
回复
贴下控制台报错啊
lkrexe8 2016-03-29
  • 打赏
  • 举报
回复
u010307827 2016-03-29
  • 打赏
  • 举报
回复
到tomcat下查看一下生成的webapp,你访问的那个工程在那里面生成一致的工程名没,工程名要一致,有可能这种错误。。。
lkrexe8 2016-03-29
  • 打赏
  • 举报
回复
上面那些就是我的控制台信息,之前换了个号上传了
qq_34113248 2016-03-29
  • 打赏
  • 举报
回复
三月 29, 2016 4:55:07 下午 org.apache.catalina.core.StandardContext startInternal 严重: One or more listeners failed to start. Full details will be found in the appropriate container log file 三月 29, 2016 4:55:08 下午 org.apache.catalina.util.SessionIdGeneratorBase createSecureRandom 信息: Creation of SecureRandom instance for session ID generation using [SHA1PRNG] took [440] milliseconds. 三月 29, 2016 4:55:08 下午 org.apache.catalina.core.StandardContext startInternal 严重: Context [/hospital] startup failed due to previous errors 三月 29, 2016 4:55:08 下午 org.apache.catalina.core.ApplicationContext log 信息: Closing Spring root WebApplicationContext 三月 29, 2016 4:55:08 下午 org.apache.catalina.loader.WebappClassLoaderBase clearReferencesJdbc 严重: The web application [/hospital] registered the JDBC driver [com.mysql.jdbc.Driver] but failed to unregister it when the web application was stopped. To prevent a memory leak, the JDBC Driver has been forcibly unregistered. 三月 29, 2016 4:55:08 下午 org.apache.catalina.loader.WebappClassLoaderBase clearReferencesThreads 严重: The web application [/hospital] appears to have started a thread named [Timer-0] but has failed to stop it. This is very likely to create a memory leak. 三月 29, 2016 4:55:08 下午 org.apache.catalina.startup.HostConfig deployDescriptor 信息: Deployment of configuration descriptor D:\apache-tomcat-7.0.68\conf\Catalina\localhost\hospital.xml has finished in 11,788 ms 三月 29, 2016 4:55:08 下午 org.apache.catalina.startup.HostConfig deployDescriptor 信息: Deploying configuration descriptor D:\apache-tomcat-7.0.68\conf\Catalina\localhost\hotel.xml 三月 29, 2016 4:55:08 下午 org.apache.catalina.startup.HostConfig deployDescriptor 警告: A docBase D:\apache-tomcat-7.0.68\webapps\hotel inside the host appBase has been specified, and will be ignored 三月 29, 2016 4:55:08 下午 org.apache.catalina.startup.SetContextPropertiesRule begin 警告: [SetContextPropertiesRule]{Context} Setting property 'source' to 'org.eclipse.jst.jee.server:hotel' did not find a matching property. 三月 29, 2016 4:55:11 下午 org.apache.catalina.startup.TldConfig execute 信息: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time. 三月 29, 2016 4:55:11 下午 org.apache.catalina.core.ApplicationContext log 信息: No Spring WebApplicationInitializer types detected on classpath 三月 29, 2016 4:55:11 下午 org.apache.catalina.core.ApplicationContext log 信息: Initializing Spring root WebApplicationContext 三月 29, 2016 4:55:11 下午 org.springframework.web.context.ContextLoader initWebApplicationContext 信息: Root WebApplicationContext: initialization started 三月 29, 2016 4:55:12 下午 org.springframework.context.support.AbstractApplicationContext prepareRefresh 信息: Refreshing Root WebApplicationContext: startup date [Tue Mar 29 16:55:12 CST 2016]; root of context hierarchy 三月 29, 2016 4:55:12 下午 org.springframework.beans.factory.xml.XmlBeanDefinitionReader loadBeanDefinitions 信息: Loading XML bean definitions from ServletContext resource [/WEB-INF/applicationContext.xml] 三月 29, 2016 4:55:12 下午 org.springframework.beans.factory.support.DefaultListableBeanFactory preInstantiateSingletons 信息: Pre-instantiating singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@69910ee1: defining beans [dataSource,sessionFactory,transactionManager,userDao,userServiceTarget,userService,saveUserAction,listUserAction,removeUserAction,updatePUserAction,updateUserAction,userAction,adminDao,adminServiceTarget,adminService,saveAdminAction,adminServiceAction,roomDao,roomServiceTarget,roomService,saveRoomAction,listRoomAction,removeRoomAction,updatePRoomAction,updateRoomAction,orderDao,orderServiceTarget,orderService,saveOrderAction,orderServiceAction,listOrderAction]; root of factory hierarchy SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder". SLF4J: Defaulting to no-operation (NOP) logger implementation SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
qq_34113248 2016-03-29
  • 打赏
  • 举报
回复
引用 3 楼 Spring_fei 的回复:
404是页面错误啊 你那么是没配置好,要么就是地址输错了
其它项目正常,就这个运行不了 而且地址输过几次,应该不是地址问题
qq_34113248 2016-03-29
  • 打赏
  • 举报
回复
三月 29, 2016 4:55:13 下午 org.springframework.orm.hibernate3.LocalSessionFactoryBean buildSessionFactory 信息: Building new Hibernate SessionFactory 三月 29, 2016 4:55:14 下午 org.springframework.orm.hibernate3.HibernateTransactionManager afterPropertiesSet 信息: Using DataSource [org.apache.commons.dbcp.BasicDataSource@5815b565] of Hibernate SessionFactory for HibernateTransactionManager 三月 29, 2016 4:55:14 下午 org.springframework.web.context.ContextLoader initWebApplicationContext 信息: Root WebApplicationContext: initialization completed in 2839 ms 三月 29, 2016 4:55:14 下午 com.opensymphony.xwork2.util.logging.commons.CommonsLogger info 信息: Parsing configuration file [struts-default.xml] 三月 29, 2016 4:55:15 下午 com.opensymphony.xwork2.util.logging.commons.CommonsLogger info 信息: Parsing configuration file [struts-plugin.xml] 三月 29, 2016 4:55:15 下午 com.opensymphony.xwork2.util.logging.commons.CommonsLogger info 信息: Parsing configuration file [struts.xml] 三月 29, 2016 4:55:15 下午 com.opensymphony.xwork2.util.logging.commons.CommonsLogger info 信息: Initializing Struts-Spring integration... 三月 29, 2016 4:55:15 下午 com.opensymphony.xwork2.util.logging.commons.CommonsLogger info 信息: Setting autowire strategy to name 三月 29, 2016 4:55:15 下午 com.opensymphony.xwork2.util.logging.commons.CommonsLogger info 信息: ... initialized Struts-Spring integration successfully 三月 29, 2016 4:55:16 下午 org.apache.catalina.startup.HostConfig deployDescriptor 信息: Deployment of configuration descriptor D:\apache-tomcat-7.0.68\conf\Catalina\localhost\hotel.xml has finished in 8,676 ms 三月 29, 2016 4:55:16 下午 org.apache.catalina.startup.HostConfig deployDescriptor 信息: Deploying configuration descriptor D:\apache-tomcat-7.0.68\conf\Catalina\localhost\library.xml 三月 29, 2016 4:55:16 下午 org.apache.catalina.startup.HostConfig deployDescriptor 警告: A docBase D:\apache-tomcat-7.0.68\webapps\library inside the host appBase has been specified, and will be ignored 三月 29, 2016 4:55:16 下午 org.apache.catalina.startup.SetContextPropertiesRule begin 警告: [SetContextPropertiesRule]{Context} Setting property 'source' to 'org.eclipse.jst.jee.server:library' did not find a matching property. 三月 29, 2016 4:55:17 下午 org.apache.catalina.startup.TldConfig execute 信息: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time. 三月 29, 2016 4:55:17 下午 org.apache.catalina.startup.HostConfig deployDescriptor 信息: Deployment of configuration descriptor D:\apache-tomcat-7.0.68\conf\Catalina\localhost\library.xml has finished in 178 ms 三月 29, 2016 4:55:17 下午 org.apache.catalina.startup.HostConfig deployDescriptor 信息: Deploying configuration descriptor D:\apache-tomcat-7.0.68\conf\Catalina\localhost\PatientInfo.xml 三月 29, 2016 4:55:17 下午 org.apache.catalina.startup.HostConfig deployDescriptor 警告: A docBase D:\apache-tomcat-7.0.68\webapps\PatientInfo inside the host appBase has been specified, and will be ignored 三月 29, 2016 4:55:17 下午 org.apache.catalina.startup.SetContextPropertiesRule begin 警告: [SetContextPropertiesRule]{Context} Setting property 'source' to 'org.eclipse.jst.jee.server:PatientInfo' did not find a matching property. 三月 29, 2016 4:55:17 下午 org.apache.catalina.startup.TldConfig execute 信息: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time. 三月 29, 2016 4:55:17 下午 org.apache.catalina.startup.HostConfig deployDescriptor 信息: Deployment of configuration descriptor D:\apache-tomcat-7.0.68\conf\Catalina\localhost\PatientInfo.xml has finished in 193 ms 三月 29, 2016 4:55:17 下午 org.apache.catalina.startup.HostConfig deployDescriptor 信息: Deploying configuration descriptor D:\apache-tomcat-7.0.68\conf\Catalina\localhost\zysx.xml 三月 29, 2016 4:55:17 下午 org.apache.catalina.startup.HostConfig deployDescriptor 警告: A docBase D:\apache-tomcat-7.0.68\webapps\zysx inside the host appBase has been specified, and will be ignored 三月 29, 2016 4:55:17 下午 org.apache.catalina.startup.SetContextPropertiesRule begin 警告: [SetContextPropertiesRule]{Context} Setting property 'source' to 'org.eclipse.jst.jee.server:zysx' did not find a matching property. 三月 29, 2016 4:55:21 下午 org.apache.catalina.startup.TldConfig execute 信息: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time. 三月 29, 2016 4:55:21 下午 org.apache.catalina.core.ApplicationContext log 信息: No Spring WebApplicationInitializer types detected on classpath 三月 29, 2016 4:55:21 下午 org.apache.catalina.startup.HostConfig deployDescriptor 信息: Deployment of configuration descriptor D:\apache-tomcat-7.0.68\conf\Catalina\localhost\zysx.xml has finished in 4,625 ms 三月 29, 2016 4:55:21 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory D:\apache-tomcat-7.0.68\webapps\docs 三月 29, 2016 4:55:22 下午 org.apache.catalina.startup.TldConfig execute 信息: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time. 三月 29, 2016 4:55:22 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deployment of web application directory D:\apache-tomcat-7.0.68\webapps\docs has finished in 182 ms 三月 29, 2016 4:55:22 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory D:\apache-tomcat-7.0.68\webapps\examples 三月 29, 2016 4:55:23 下午 org.apache.catalina.startup.TldConfig execute 信息: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time. 三月 29, 2016 4:55:23 下午 org.apache.catalina.core.ApplicationContext log 信息: ContextListener: contextInitialized() 三月 29, 2016 4:55:23 下午 org.apache.catalina.core.ApplicationContext log 信息: SessionListener: contextInitialized() 三月 29, 2016 4:55:23 下午 org.apache.catalina.core.ApplicationContext log 信息: ContextListener: attributeAdded('org.apache.jasper.compiler.TldLocationsCache', 'org.apache.jasper.compiler.TldLocationsCache@219f8528') 三月 29, 2016 4:55:23 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deployment of web application directory D:\apache-tomcat-7.0.68\webapps\examples has finished in 1,134 ms 三月 29, 2016 4:55:23 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory D:\apache-tomcat-7.0.68\webapps\host-manager 三月 29, 2016 4:55:23 下午 org.apache.catalina.startup.TldConfig execute 信息: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time. 三月 29, 2016 4:55:23 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deployment of web application directory D:\apache-tomcat-7.0.68\webapps\host-manager has finished in 163 ms 三月 29, 2016 4:55:23 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory D:\apache-tomcat-7.0.68\webapps\manager 三月 29, 2016 4:55:23 下午 org.apache.catalina.startup.TldConfig execute 信息: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time. 三月 29, 2016 4:55:23 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deployment of web application directory D:\apache-tomcat-7.0.68\webapps\manager has finished in 128 ms 三月 29, 2016 4:55:23 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deploying web application directory D:\apache-tomcat-7.0.68\webapps\ROOT 三月 29, 2016 4:55:23 下午 org.apache.catalina.startup.TldConfig execute 信息: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time. 三月 29, 2016 4:55:23 下午 org.apache.catalina.startup.HostConfig deployDirectory 信息: Deployment of web application directory D:\apache-tomcat-7.0.68\webapps\ROOT has finished in 144 ms 三月 29, 2016 4:55:23 下午 org.apache.coyote.AbstractProtocol start 信息: Starting ProtocolHandler ["http-apr-8080"] 三月 29, 2016 4:55:23 下午 org.apache.coyote.AbstractProtocol start 信息: Starting ProtocolHandler ["ajp-apr-8009"] 三月 29, 2016 4:55:23 下午 org.apache.catalina.startup.Catalina start 信息: Server startup in 27511 ms
Spring_fei 2016-03-29
  • 打赏
  • 举报
回复
404是页面错误啊 你那么是没配置好,要么就是地址输错了
Ayiliu 2016-03-29
  • 打赏
  • 举报
回复
你看看myeclipse的web的是hospital吗 我感觉你那个应该不是吧

81,114

社区成员

发帖
与我相关
我的任务
社区描述
Java Web 开发
社区管理员
  • Web 开发社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧