| [news.eclipse.webtools] Re: Problems debugging a WAR with Tomcat |
Larry Isaacs wrote:
When starting the Tomcat server, there is a "ping" thread started that tries to establish a connection to Tomcat. When that succeeds, the Servers view transitions that Tomcat server from "starting" to "started"
or "debugging". If "ping" doesn't succeed within the timeout, it assumes startup failed and it kills the Tomcat process. I don't have any explanation as to why Run on Server succeeds and Debug doesn't.
I recommend the following to gather more clues. Unzip the Tomcat binary into a new directory to get a fresh default copy. Create a new Tomcat runtime and server from that fresh Tomcat. Try Debug on Server and Run on Server and see what happens. Hopefully this will tell us if there is something different about your system that is triggering this behavior, or it's something about changes to the Tomcat configuration.
Note, selecting "Use Tomcat installation..." is not in any way required for debugging. How to best configure things for debugging kind of depends on exactly what you mean by debugging and how badly you want to avoid restarts.
Cheers, Larry
Alejandro wrote:C:SunSDKjdkbin;.;C:WINDOWSSunJavabin;C:WINDOWSsystem32;C:WINDOWS;C:SunSDKjdkjrebin;C:/Sun/SDK/jdk/bin/../jre/bin/client;C:/Sun/SDK/jdk/bin/../jre/bin;C:WINDOWSsystem32;C:WINDOWS;C:WINDOWSSystem32Wbem;C:SunSDKjdkbin;C:ArchivosHi Larry, thanks for your quick response.
I will try to answer your questions:
Does Run -> Run on Server behave the same or different?
Nope, in that case, Tomcat starts with no problem and I can try my web application with no probs
What OS are you running on?
Windows XP SP3, no firewall, no anti-virus enabled. As I mentioned on the previous post, before trying Tomcat, I used Glassfish v3 and it worked great, no problems at all.
Was this Tomcat customized before creating the runtime and server from it in Eclipse, or did it still have it's default settings?
Fresh install and default settings for Tomcat. Only changed the port to 80. Only thing I changed (as I saw someone mention it is required for debugging) is that I let Eclipse take control of the Tomcat instalation, and checked the "Never publish automatically" checkbox. Besides that, nothing has changed.
Towards the console output when I try to debug on Tomcat:
1-may-2009 14:54:53 org.apache.tomcat.util.digester.SetPropertiesRule begin
ADVERTENCIA: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.j2ee.server:UCH' did not find a matching property.
21-may-2009 14:54:53 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:
de programaTortoiseSVNbin;C:SunSDKjdkbin 21-may-2009 14:54:53 org.apache.coyote.http11.Http11Protocol init INFO: Inicializando Coyote HTTP/1.1 en puerto http-80 21-may-2009 14:54:53 org.apache.catalina.startup.Catalina load INFO: Initialization processed in 946 ms 21-may-2009 14:54:53 org.apache.catalina.core.StandardService start INFO: Arrancando servicio Catalina 21-may-2009 14:54:53 org.apache.catalina.core.StandardEngine start INFO: Starting Servlet Engine: Apache Tomcat/6.0.18 edu.wisc.trace.uch.UCH.<init> (Line: 135) INFO: IP Address =172.22.50.20
I can debug until the timeout expires...then the thread is killed. I tried to look on the Tomcat/logs for a recent log but the newest is from yesterday...the previous was the console output.
Thanks in advance...this is puzzling me...
Hi again Larry,
eclipse.buildId=M20080911-1700 java.version=1.6.0_10 java.vendor=Sun Microsystems Inc. BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=es_ES Command-line arguments: -os win32 -ws win32 -arch x86
Error Fri May 22 10:05:28 CEST 2009 Problems occurred when invoking code from plug-in: "org.eclipse.jface".
Best regards and many thanks for your advices
Alejandro