Paul and Chuck,
On 7/3/2016 4:14 PM, Caldarale, Charles R wrote:
>> From: Paul Roubekas [mailto:paul@orthogroup.holdings] Subject: Re:
>> Servlet <welcome-file-list> overridden by Apache Tomcat welcome
>> page?
> 
>> After making the above suggested changes the desired behavior goes 
>> away.  Now instead of my application's landing page I get the
>> tomcat welcome page.
> 
> You appear to have ignored what Hassan S said earlier in this thread;
> I'll repeat it here:
> 
> "Assuming a default installation, you should see the index.jsp page 
> associated with the *default context*, which in Tomcat is named ROOT
> (case sensitive).
> 
> "You need to move or delete the existing ROOT and rename your own WAR
> file (or directory) to ROOT."
> 
> I suspect you did not delete the existing ROOT directory.
> 
>> I am using Eclipse Mars.2  Is it possible I simply implemented the
>> suggestions incorrectly?  Below is what eclipse did to the
>> server.xml file.
> 
>> <Context docBase="C:\apache-tomee-plume\wtpwebapps\ROOT##000" 
>> path="/ROOT##000" reloadable="true" 
>> source="org.eclipse.jst.jee.server:ROOT##000">
> 
> I'm not an Eclipse user, but any IDE that blindly updates
> configuration files without your explicit permission sounds extremely
> dangerous.  Others may have suggestions about how to stop such bad
> behavior.  You really, really do not want to put any <Context>
> elements in server.xml.
> 
> - Chuck

I just played with Eclipse Neon (newest release). It does copy over a
Tomcat configuration into your workspace, and then runs Tomcat from that
(sort of like RUNNING.txt).

That being said, Eclipse does not handle ROOT well at all by default. If
I tell Maven to have a final name of ROOT, then Eclipse edits the
workspace server.xml with:

<Host>
<Context docBase="CSEFive"
   path="/ROOT"
   reloadable="true"
   source="org.eclipse.jst.jee.server:CSEFive"/>
</Host>

CSEFive is my actual application.

If I name things normally, then the application comes up as CSEFive, and
the portion of server.xml reads as follows:

<Host>
<Context
   docBase="CSEFive"
   path="/CSEFive"
   reloadable="true"
   source="org.eclipse.jst.jee.server:CSEFive"/>
</Host>

The only way that I know of to manage this from within Eclipse is the
following:

Right-mouse click on the project, and go the the following in the drop
down menu:

Properties->Web Project Settings

Change the Context root to /

Run your project from within Eclipse, and it will come up as
http://localhost:8080/

Eclipse will rewrite the server.xml in your workspace to:

<Host>
<Context
   docBase="CSEFive"
   path="/"
   reloadable="true"
   source="org.eclipse.jst.jee.server:CSEFive"/>
</Host>

In any case, once you move out of an Eclipse-controlled Tomcat, the WAR
file needs to be named ROOT.war (case matters, even on Windows).

You'll need to move Tomcat's default ROOT web application to another
location.

In short, it's an Eclipse artifact.

. . . just my two cents
/mde/

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to