This is the response I got to my bug submission:

====================================================================================
(In reply to Mark Barnes from comment #0)

> In my server.xml, in my <Host> element, I have name='wapp1_001" and > 
> appBase=””.

Invalid right off the bat.

> Buth when I use appBase="" it doesn't work.

Nor should it, since that's an invalid configuration.

Bugzilla is not a support forum; post your configuration issues on the Tomcat 
users' mailing list.

======================================================================================


It works for Tomcat 6 and it worked for Tomcat 5. We're upgrading from 6.0.20 
to 8.0.14.

The configuration reference does say this:

The Application Base directory for this virtual host. This is the pathname of a 
directory that may contain web applications to be deployed on this virtual 
host. You may specify an absolute pathname, or a pathname that is relative to 
the $CATALINA_BASE directory. See Automatic Application Deployment for more 
information on automatic recognition and deployment of web applications. If not 
specified, the default of webapps will be used.

I get that it does NOT say that appBase="" is the same as not specifying 
appBase at all. In fact, it doesn't say what appBase="" means. It doesn't say 
it's invalid, either. So "" is not relative $CATALINA_BASE ???

The Document Base (also known as the Context Root) directory for this web 
application, or the pathname to the web application archive file (if this web 
application is being executed directly from the WAR file). You may specify an 
absolute pathname for this directory or WAR file, or a pathname that is 
relative to the appBase directory of the owning Host. The value of this field 
must not be set unless the Context element is defined in server.xml or the 
docBase is not located under the Host's appBase. If a symbolic link is used for 
docBase then changes to the symbolic link will only be effective after a Tomcat 
restart or by undeploying and redeploying the context. A context reload is not 
sufficient.

Oh, well...

> -----Original Message-----
> From: Barnes, Mark (CORP) [mailto:mark.bar...@adp.com]
> Sent: Monday, January 19, 2015 2:52 PM
> To: Tomcat Users List
> Subject: Tomcat 8.0.14 - Using the Wrong Webapp Directory?
> 
> 
> 
> It looks to me like Tomcat 8.0.14 is trying to use the wrong directory when
> trying to load a web app.
> 
> In my server.xml, in my <Host> element, I have name='wapp1_001" and
> appBase=””.  In my <Context> element, I have path=”/src” and
> docBase=”webapps/src”
> 
> I would expect Tomcat to use $TOMCAT_HOME/webapps/src for the /src
> context, but it's not.  It's trying to use $TOMCAT_HOME/src.  Why?
> 
> Both TOMCAT_HOME and CATALINA_HOME are set to /usr/local/tomcat,
> which is a symbolic link to /usr/local/tomcat8, which is a symbolic to
> /usr/local/apache-tomcat-8.0.14.
> 
> When I use appBase="/usr/local/tomcat/webapps" things work just fine.  Notice
> that "webapps" is now in both appBase and docBase.
> 
> When I use appBase="webapps" things work just fine as well.  Notice that
> "webapps" is redundant again.
> 
> Buth when I use appBase="" it doesn't work.
> 
> The Tomcat 8 configuration docs seem to say that the default for appBase is
> the "webapps" sub-directory of $TOMCAT_HOME, as it always has been.
> 
> I have had this same problem on both Windows 7 and Ubuntu Linux.  JDK is
> 1.8.0_25 (64-bit) in both cases
> 
> Am I missing something here?  Did somethning change between Tomcat 6 and
> Tomcat 8.  Or is this a bug in Tomcat 8.0.14?
> 
> 
> 
> 
> Here is info from the stack traceback:
> 
> java.util.concurrent.ExecutionException:
> org.apache.catalina.LifecycleException: Failed to start component
> [StandardEngine[Tomcat-
> Standalone].StandardHost[wapp1_001].StandardContext[/src]]
>   at java.util.concurrent.FutureTask.report(FutureTask.java:122)
>   at java.util.concurrent.FutureTask.get(FutureTask.java:192)
>   at
> org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:916)
>   at 
> org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:868)
>   at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
>   at
> org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:140
> 8)
>   at
> org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:139
> 8)
>   at java.util.concurrent.FutureTask.run(FutureTask.java:266)
>   at
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1
> 142)
>   at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:
> 617)
>   at java.lang.Thread.run(Thread.java:745)
> Caused by: org.apache.catalina.LifecycleException: Failed to start component
> [StandardEngine[Tomcat-
> Standalone].StandardHost[wapp1_001].StandardContext[/src]]
>   at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
>   ... 6 more
> Caused by: org.apache.catalina.LifecycleException: Failed to start component
> [org.apache.catalina.webresources.StandardRoot@6672f1f2]
>   at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
>   at
> org.apache.catalina.core.StandardContext.resourcesStart(StandardContext.java
> :4900)
>   at
> org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5
> 029)
>   at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
>   ... 6 more
> Caused by: java.lang.IllegalArgumentException: The main resource set
> specified [/usr/local/apache-tomcat-8.0.14/src] is not valid
>   at
> org.apache.catalina.webresources.StandardRoot.startInternal(StandardRoot.jav
> a:665)
>   at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
>   ... 9 more
> 01-19-2015 14:16:03.524 A child container failed during start
> 
> 
> 
> I have submitted a bug report for this.
> 
> ----------------------------------------------------------------------
> This message and any attachments are intended only for the use of the
> addressee and may contain information that is privileged and confidential. If
> the reader of the message is not the intended recipient or an authorized
> representative of the intended recipient, you are hereby notified that any
> dissemination of this communication is strictly prohibited. If you have 
> received
> this communication in error, notify the sender immediately by return email and
> delete the message and any attachments from your system.
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
> 


----------------------------------------------------------------------
This message and any attachments are intended only for the use of the addressee 
and may contain information that is privileged and confidential. If the reader 
of the message is not the intended recipient or an authorized representative of 
the intended recipient, you are hereby notified that any dissemination of this 
communication is strictly prohibited. If you have received this communication 
in error, notify the sender immediately by return email and delete the message 
and any attachments from your system.

Reply via email to