tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Shapira, Yoav" <Yoav.Shap...@mpi.com>
Subject RE: Problem deploying WAR with META-INF/context.xml file (probably a bug) with Tomcat 5 (for W2K)
Date Thu, 26 Aug 2004 12:58:33 GMT

Hi,
This is a known bug in 5.0.27.  You can use 5.0.25 which has correct
behavior here.  I've also already patched the bug in CVS, and I'll cut
out a 5.0.28 release in a few days which will have the fix.

Yoav Shapira
Millennium Research Informatics


>-----Original Message-----
>From: Daniel CAMPI [mailto:tomcat@ribosomes.com]
>Sent: Thursday, August 26, 2004 5:03 AM
>To: tomcat-user@jakarta.apache.org
>Subject: Problem deploying WAR with META-INF/context.xml file (probably
a
>bug) with Tomcat 5 (for W2K)
>
>Hi,
>
>I'm just discovering Tomcat 5, and I've been spending almost all day
trying
>to find a solution to deploy a WAR packaged servlet that has to connect
>itself to a global data source resource (ORACLE database).
>
>To set up the connections, I first did the things manually. From within
the
>web Administration Tool I executed the followin actions:
>
>a) I configured a GLOBAL [Data Source] resource
>b) I declared a local (CONTEXT or application specific) [Resource Link]
>pointing to the GLOBAL [Data Source]
>
>Great, everything works fine so far: I can see my data !
>
>
>But then, I thought, it would be great if I could separate server
specific
>tasks (like declaring GLOBAL resources) from servlet specific tasks
(like
>declaring local links to these external resources). So, I could have a
>global resource called [MyGlobalDatabase] that could be configured in
>different ways on different Tomcat servers (on a test server, this
resource
>could point to a test database...).
>
>On the other hand, the only thing my servlets should be aware of, is
that
>they will find a global resource called [MyGlobalDatabase] on their
Tomcat
>server. They don't need to know what's the actual configuration behind
this
>resource name, but they need to know how to connect to that resource.
This
>is specially important during servlet deployment: I would like to
package
>my
>servlets  in a way that no manual intervention is required by the
Tomcat
>server administrator (except, of course, loading the *.WAR package) !
>
>So I read all the documentation I could find about this topic, and I
>discovered that it was possible to define context specific resources
from
>within a *.WAR file. All I was supposed to do, was to create a
/META-INF/
>directory containing a [context.xml] file, and declare my links from
within
>that file !
>
>I followed all the steps, but when I deployed my *.WAR file, the link
was
>not set up correctly. I checked the CONTEXT specific resources of my
>servlet
>from within the Administration Tool, and there wasen't any link
declared.
>
>So I had a look at my ${tomcat_root}\conf\Catalina\localhost directory
to
>see if my [myservlet.xml] file was there, and here comes the surprise:
>
>There was indeed something called [myservlet.xml]  at that place: but
it
>wasn't an *.xml file... It was an empty directory !!!!!!!
>
>
>My question: did someone already succeed in deploying a servlet using a
>/META-INF/context.xml file with Tomcat 5 (OS: W2K), or is this a known
bug,
>and all I can do is to wait for a new release of Tomcat ?
>
>
>Thank you very much for your help,
>
>D. Campi
>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: tomcat-user-help@jakarta.apache.org




This e-mail, including any attachments, is a confidential business communication, and may
contain information that is confidential, proprietary and/or privileged.  This e-mail is intended
only for the individual(s) to whom it is addressed, and may not be saved, copied, printed,
disclosed or used by anyone else.  If you are not the(an) intended recipient, please immediately
delete this e-mail from your computer system and notify the sender.  Thank you.


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Mime
View raw message