Win a copy of Svelte and Sapper in Action this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Bear Bibeault
  • Junilu Lacar
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • salvin francis
  • Frits Walraven
Bartenders:
  • Scott Selikoff
  • Piet Souris
  • Carey Brown

How ecllipse program running differ from non IDE running

 
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

1>If I'm manually starting tomcat and executing a web app then i'm mentioning the port no. in server.xml
but if I'm using IDE eclipse then why I don't need to mention anything in server.xml........

2>If I'm not using IDE eclipse then to test tomcat I use URL:http://localhost:8012/
But If I copy url from eclipse browser and edit it to http://localhost:8019/ and run it then resource not found(Http 404 error)....why???

Description of 2>

In my eclipse if I'm running any web app in eclipse which uses port 8019 and I'm pasting that in
browser it works f9.
for ex:

http://localhost:8019/test34/NewFile.jsp



But if I use Url :

http://localhost:8019/

then i'm getting http status 404 resource not found error.why???

I didn't mention anything regarding this port:8019 in server.xml still how it is working???


thanks in advance
 
Saloon Keeper
Posts: 22492
151
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The server.xml file always defines the port numbers used by Tomcat. What you are actually doing, it appears, is supplanting the distribution version's port 8080 with your own 8019. Or is it 8012?

There are several ways to run Tomcat under Eclipse. One of the most popular ways to do so is to use the server control component that's part of the WTP plugin that is bundled into the J2EE spin of Eclipse.

I don't like this component and your problem is one reason why. The WTP Tomcat plugin makes private copies of some, but not all of Tomcat's configuration files and uses them. If you change the original config files, you then have to kick WTP until it imports the changes; they are not adopted automatically. And if you need something configured that's not in WTP's narrow set of features, you are out of luck.

One way to get around that is to launch Tomcat in debug mode and connect as a remote debugging session. Most of the Tomcat control plugins basically do that anyway, but if you start Tomcat manually, you get the Tomcat configuration that's actually in Tomcat.

Another way is to install the sysdeo Tomcat plugin. This plugin basically does what manual starting of an external Tomcat does except that it allows Eclipse to do the start/stop/restart and it redirects catalina.out to the Eclipse console window. I use sysdeo and highly recommend it. It's fairly easy to install and it doesn't conflict with the WTP plugin so there won't be any problems installing it in the J2EE Eclipse.
 
No matter how many women are assigned to the project, a pregnancy takes nine months. Much longer than this tiny ad:
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
    Bookmark Topic Watch Topic
  • New Topic