Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Web Tools Project (WTP) » Eclipse fails to monitor embedded tomcat(Tomcat does startup but Eclipse does not detect it)
Eclipse fails to monitor embedded tomcat [message #662233] Tue, 29 March 2011 15:28 Go to next message
Eric Chavet is currently offline Eric Chavet
Messages: 3
Registered: March 2011
Junior Member
Hello,

WTP drives me crazy:
I'm using Helios Service release 2 with tomcat 7 on Mac OSX.

I can't start my embedded tomcat server because Eclipse does not monitor it correctly. The server does start-up but Eclipse still waits for it to start-up and then stops it when the timeout occurs.

The server remains usable as far as the timeout does not occur. I have tried with Tomcat 6, with other ports but no success.

Any idear?

Thanks
Re: Eclipse fails to monitor embedded tomcat [message #662234 is a reply to message #662233] Tue, 29 March 2011 15:34 Go to previous messageGo to next message
Eric Chavet is currently offline Eric Chavet
Messages: 3
Registered: March 2011
Junior Member
Haaa!!
I'm so stupid! Laughing

I had changed the Server Host Name thinking it was a logical name but that was its network name! It had to be "localhost".

Sorry for the message.
Re: Eclipse fails to monitor embedded tomcat [message #662242 is a reply to message #662234] Tue, 29 March 2011 16:09 Go to previous message
Larry Isaacs is currently offline Larry Isaacs
Messages: 1305
Registered: July 2009
Senior Member
On 3/29/2011 3:34 PM, Eric Chavet wrote:
> Haaa!!
> I'm so stupid! :lol:
> I had changed the Server Host Name thinking it was a logical name but
> that was its network name! It had to be "localhost".
>
> Sorry for the message.

It doesn't have to be "localhost", but for whatever is specified for the
host name, then the equivalent of the following Java code has to be
successful in establishing a connection and not throw an exception prior
to the timeout:

URL pingUrl = new URL("http://<host_name>:<port>");
URLConnection conn = pingUrl.openConnection();
((HttpURLConnection)conn).getResponseCode();

In the default configuration for Tomcat, the <Host> element is
configured for "localhost" in the server.xml. I believe this would
imply that the host_name you specify will need to resolve to "localhost"
for this to work. It it can, I would expect that host_name to
successfully detect the Tomcat start up.

Cheers,
Larry
Previous Topic:Java EE wizards not working. Only EAR Wizard works
Next Topic:Unable to start JBOSS 5 from eclise IDE [Galileo]
Goto Forum:
  


Current Time: Sat Aug 23 09:43:21 EDT 2014

Powered by FUDForum. Page generated in 0.07720 seconds