Java Mailing List Archive

http://www.junlu.com/

Google
Google
Mailing List
Home
Forum Home
JBoss - Java Application Server
Struts - A MVC web framework
Tomcat - JSP/Servlet container
iText - An open source PDF Java Library
JDOM - JDOM XML Parser
J2EE - A mailing list for Java(tm) 2 Platform, Enterprise Edition
J2EE Pattern - An interest list for Sun Java Center J2EE Pattern Catalog
Servlet - A mailing list for discussion about Sun Microsystem's Java Servlet API Technology
JSP - A mailing list about Java Server Pages specification and reference
Struts & Hibernate
Subjects
JSP editor plugin for eclipse ?
org apache jasper JasperException: Unable to compile class for JSP
Tomcat: Connection reset by peer: socket write error
Cannot retrieve definition for form bean null
Struts Tiles Tutorial (free Struts training)
Where do I download Tomcat 4 0 6?
Data Access Object (DAO) pattern, example DAO 's
Where to download Tomcat v 4 1 24 from?
Tomcat 5 0 16 Requested resource not available
Oracle Connection Pooling in 3 2 2
Servlet : Session invalidate
Servlet action is currently unavailable
Tomcat/Struts Unicode Encoding/Decoding problems
Tomcat and webapplication specific java library path
Running a Simple JMS Example
Mapping in workers2 properties
org apache jasper JasperException
Cannot find message resources under key org apache struts action
   MESSAGE
problem with html:text bean throwing exception
Cannot find message resources under key org apache struts action MESSAGE
invalid direct reference problem with solution
Tool for jsp debug Try Sysdeo Eclipse Plugin
Tomcat 5 Cannot load JDBC driver class 'null ' SQL state: null
weblogic ejbc
java properties file
Jboss 3 2 3 Coyote Can 't re
Tomcat 5, Apache2 and mod jk2 integration problem
JBoss example problem new to J2EE
url string for connecting jboss to oracle
Value attribute of <html:checkbox
javax servlet ServletException: BeanUtils populate
HTTP Status 404 The requested resource is not available
5 0 18: Windows XP Pro vs Windows 2000
 
Deploying with Static Context Descriptors

Deploying with Static Context Descriptors

2006-04-03       - By sean.harrison@(protected)

 Back
Reply:     1     2     3     4     5  

I'm migrating web applications from Tomcat v.4 to v.5.5 and having some
trouble adapting my old virtual hosts setup with the 5.5 recommended
methods.

According to http://tomcat.apache.org/tomcat-5 (See http://cat-5.ora-code.com).5-doc/config/context.html
"In addition to nesting Context elements inside a Host element, you can
also store them: in individual files (with a ".xml" extension) in the
$CATALINA_HOME/conf/[enginename]/[hostname]/ directory"

So to make sure I know what I'm doing, I used a server.xml with this:

  <Engine name="Catalina" defaultHost="localhost">
     <Realm className="org.apache.catalina.realm.UserDatabaseRealm Source code of org.apache.catalina.realm.UserDatabaseRealm"
resourceName="UserDatabase"/>
     <Host name="localhost" appBase="webapps" unpackWARs="true"
autoDeploy="true" xmlValidation="false" xmlNamespaceAware="false">
       </Host>
   </Engine>

And then created a file $CATALINA_HOME/conf/Catalina/localhost/sean.xml
with my Context element, which reads,

<Context path="" docBase="ROOT"></Context>

But when I start Tomcat, I get surprising errors. First...

  Apr 3, 2006 3:05:13 PM org.apache.catalina.startup.HostConfig Source code of org.apache.catalina.startup.HostConfig
deployDescriptor
  WARNING: A docBase /var/tomcat5/webapps/ROOT inside the host appBase
has been specified, and will be ignored

Although Tomcat seems to be trying to read my docBase param, something is
not right. It thinks "appBase" is a host.[?] Then I get...

  Apr 3, 2006 3:05:13 PM org.apache.catalina.core.StandardContext Source code of org.apache.catalina.core.StandardContext
resourcesStart
  SEVERE: Error starting static Resources
  java.lang.IllegalArgumentException Source code of java.lang.IllegalArgumentException: Document base
/var/tomcat5/webapps/sean does not exist or is not a readable directory

Tomcat seems to be looking for a web app by the name of "sean" from the
filename "sean.xml."  But according to
http://tomcat.apache.org/tomcat-5 (See http://cat-5.ora-code.com).5-doc/deployer-howto.html "If a Context
Descriptor is... ...manually created, the filename need not match the web
application name as Tomcat is concerned only with the Context
configuration contained within the Context Descriptor file(s)."

With Tomcat 4 I had my Context Descriptors outside of server.xml and
separated by virtual hosts in individual files very similar to v5.5's
$CATALINA_HOME/conf/[enginename]/[hostname]/ approach, but now I can't
seem to get grasp how exactly v.5.5. wants it done.

What am I missing?

Thanks in advance,



S  e  a  n   H  a  r  r  i  s  o  n
-                 -                 -
Internet Services Administrator
Lincoln, Nebraska

-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ------
To unsubscribe, e-mail: users-unsubscribe@(protected)
For additional commands, e-mail: users-help@(protected)


©2008 junlu.com - Jax Systems, LLC, U.S.A.