Thanks! Your reply is an excellent summary of the relationship between <GlobalNamingResources> in server.xml, <ResourceLink> in <Context>, and <resource-ref> in the deployment descriptor. It's too bad that "Tomcat: The Definitive Guide" does not describe it quite so well! Because of all of these references, I found resources to be one of the most difficult Tomcat features to understand and configure. Your summary of this relationship and makes it so much easier to understand!
Derek -----Original Message----- From: Christopher Schultz [mailto:[EMAIL PROTECTED] Sent: November 19, 2003 8:31 AM To: Tomcat Users List Subject: Re: Relationship between server.xml/Resource and web.xml/resource-ref. Florian, > Is it completely up to the developers/deployers wether the necessary > resources get declared in the server or in the application? This is correct. > Is it just > for convenience, so that deployer doesn't have to unpack the WAR? No, this has nothing to do with unpacking WAR files. > Or -- > like someone stated on this list (to my confusion) -- that the > server.xml Resource element and the web.xml resource-ref have a relation > that is similar to that of an implementation class instance and an > interface? This is an apt analogy. The server.xml sets up the actual resource (often in the <GlobalNamingResources> section), then allows the application to use it (by adding a <ResourceLink> section in the <Context> where you want to use it). The webapp signifies its desire to use that resource by including a complimentary <resource-ref> section in the deployment descriptor. -chris --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
