我有一个J2EE Web项目,使用Struts和Hibernate。它在我的开发环境中完美地发展到几天前(我真的不知道发生了什么,我没碰到任何东西......),当它停止在Eclipse的tomcat服务器上运行时。我正在使用Eclipse Java EE kepler,JRE 6和Tomcat 5.5.36。 该项目在外部Tomcat 5.5.36上运行良好,但是当我在Eclipse上运行时,我得到:
404 - 请求的资源不可用。
控制台跟踪是:
26-nov-2013 13:43:12 org.apache.catalina.core.AprLifecycleListener init
INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: C:\Program Files\Java\jre6\bin;C:\Windows\Sun\Java\bin;C:\Windows\system32;C:\Windows;......
26-nov-2013 13:43:14 org.apache.coyote.http11.Http11BaseProtocol init
INFO: Inicializando Coyote HTTP/1.1 en puerto http-8080
26-nov-2013 13:43:14 org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 4942 ms
26-nov-2013 13:43:14 org.apache.catalina.core.StandardService start
INFO: Arrancando servicio Catalina
26-nov-2013 13:43:14 org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/5.5.36
26-nov-2013 13:43:14 org.apache.catalina.core.StandardHost start
INFO: Desactivada la validación XML
26-nov-2013 13:43:16 org.apache.catalina.core.StandardContext start
GRAVE: Error filterStart
26-nov-2013 13:43:16 org.apache.catalina.core.StandardContext start
GRAVE: Falló en arranque del Contexto [/phnemos_ph] debido a errores previos
26-nov-2013 13:43:17 org.apache.coyote.http11.Http11BaseProtocol start
错误是:
由于先前的错误,启动失败
但是我无法进一步追踪它,因为Tomcat的localhost日志是空的,它存在但是空的。
这是我的web.xml:
<jsp-config>
<jsp-property-group>
<url-pattern>*.jsp</url-pattern>
<trim-directive-whitespaces>true</trim-directive-whitespaces>
</jsp-property-group>
</jsp-config>
<display-name>PH Web Application</display-name>
<!-- Action Servlet Configuration -->
<servlet>
<servlet-name>action</servlet-name>
<servlet-class>com.tsystems.web.common.MyFrontController</servlet-class>
<init-param>
<param-name>config</param-name>
<param-value>/WEB-INF/struts-config.xml</param-value>
</init-param>
<init-param>
<param-name>debug</param-name>
<param-value>2</param-value>
</init-param>
<init-param>
<param-name>detail</param-name>
<param-value>2</param-value>
</init-param>
<load-on-startup>2</load-on-startup>
</servlet>
<!-- Action Servlet Mapping -->
<servlet-mapping>
<servlet-name>action</servlet-name>
<url-pattern>*.do</url-pattern>
</servlet-mapping>
<!-- The Welcome File List -->
<welcome-file-list>
<welcome-file>paginas/index.jsp</welcome-file>
</welcome-file-list>
<!-- Struts Tag Library Descriptor -->
<taglib>
<taglib-uri>struts-app</taglib-uri>
<taglib-location>/WEB-INF/app.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>struts-tiles</taglib-uri>
<taglib-location>/WEB-INF/struts-tiles.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>struts-bean</taglib-uri>
<taglib-location>/WEB-INF/struts-bean.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>struts-logic</taglib-uri>
<taglib-location>/WEB-INF/struts-logic.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>struts-html</taglib-uri>
<taglib-location>/WEB-INF/struts-html.tld</taglib-location>
</taglib>
<taglib>
<taglib-uri>struts-nested</taglib-uri>
<taglib-location>/WEB-INF/struts-nested.tld</taglib-location>
</taglib>
<!-- Declaraci�n de filtros-->
<filter>
<filter-name>Filtro de Seguridad</filter-name>
<filter-class>com.tsystems.web.common.FiltroSeguridad</filter-class>
</filter>
<!-- Mapeo de filtros.Asociamos el filtro al jsp Menu.jsp-->
<filter-mapping>
<filter-name>Filtro de Seguridad</filter-name>
<url-pattern>*.do</url-pattern>
</filter-mapping>
<filter-mapping>
<filter-name>Filtro de Seguridad</filter-name>
<url-pattern>*.jsp</url-pattern>
</filter-mapping>
<!--
<security-constraint>
<web-resource-collection>
<web-resource-name>Paginas de gestion de preferencias de usuario</web-resource-name>
<url-pattern>/*</url-pattern>
<http-method>DELETE</http-method>
<http-method>GET</http-method>
<http-method>POST</http-method>
<http-method>PUT</http-method>
</web-resource-collection>
<auth-constraint>
<role-name>OPER_CPH</role-name>
</auth-constraint>
</security-constraint>
<login-config>
<auth-method>FORM</auth-method>
<form-login-config>
<form-login-page>/paginas/login/login2.jsp</form-login-page>
<form-error-page>/paginas/login/login2.jsp</form-error-page>
</form-login-config>
</login-config>
<security-role>
<description>Operador</description>
<role-name>OPER_CPH</role-name>
</security-role>
-->
<listener>
<listener-class>com.tsystems.contextListener.ContextListener</listener-class>
</listener>
</web-app>
拜托,任何小小的帮助都会很棒,因为我好几天都被困住了。谢谢!!