You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@geronimo.apache.org by Ch Praveena <ps...@gmail.com> on 2008/03/04 07:37:58 UTC

Significance of writing an additional Descriptor file

Hi,

   May i know the significance of writing geronimo-web.xml in WEB-INF, along
with web.xml, while deploying war files.

-- 
Regards,

Praveena Chalamcharla,
Securview....

Re: Significance of writing an additional Descriptor file

Posted by Hernan Cunico <hc...@gmail.com>.
This doc, although still in the making, may give you a better view of the Geronimo specific deployment plans and their role.

http://cwiki.apache.org/GMOxDOC21/deployment-plans.html

HTH

Cheers!
Hernan 

Vamsavardhana Reddy wrote:
> web.xml is the Java EE specific deployment descriptor for the web 
> application.  geronimo-web.xml is the Geronimo app server specific 
> deployment plan that usually provides mapping of any resources and other 
> configuration used by the web application.  Deployment plan can either 
> be packaged in the WAR file under WEB-INF directory (in this case the 
> file name should be geronimo-web.xml) or  specified at deployment time 
> (in this case there is no restriction on the file name used).
> 
> ++Vamsi
> 
> On Tue, Mar 4, 2008 at 12:07 PM, Ch Praveena <ps050202@gmail.com 
> <ma...@gmail.com>> wrote:
> 
>     Hi,
> 
>        May i know the significance of writing geronimo-web.xml in
>     WEB-INF, along with web.xml, while deploying war files.
> 
>     -- 
>     Regards,
> 
>     Praveena Chalamcharla,
>     Securview.... 
> 
> 

Re: Significance of writing an additional Descriptor file

Posted by Vamsavardhana Reddy <c1...@gmail.com>.
web.xml is the Java EE specific deployment descriptor for the web
application.  geronimo-web.xml is the Geronimo app server specific
deployment plan that usually provides mapping of any resources and other
configuration used by the web application.  Deployment plan can either be
packaged in the WAR file under WEB-INF directory (in this case the file name
should be geronimo-web.xml) or  specified at deployment time (in this case
there is no restriction on the file name used).

++Vamsi

On Tue, Mar 4, 2008 at 12:07 PM, Ch Praveena <ps...@gmail.com> wrote:

> Hi,
>
>    May i know the significance of writing geronimo-web.xml in WEB-INF,
> along with web.xml, while deploying war files.
>
> --
> Regards,
>
> Praveena Chalamcharla,
> Securview....

Re: Significance of writing an additional Descriptor file

Posted by Jacek Laskowski <ja...@laskowski.net.pl>.
On Mon, Mar 3, 2008 at 10:37 PM, Ch Praveena <ps...@gmail.com> wrote:

>    May i know the significance of writing geronimo-web.xml in WEB-INF, along
> with web.xml, while deploying war files.

In short...

web.xml is a java ee thingy. web.xml is mandatory in Java Servlets
2.5. Without it the war would be incorrect. You use web.xml to declare
your *logical* resource names. You declare your requirements a runtime
environment.

geronimo-web.xml is a Geronimo thingy and is optional, but helps
mapping *logical* names to their runtime counterparts. The runtime
resources are managed by application server and their access is
application server-specific. When names are the same and Geronimo can
compute their runtime representations you don't need geronimo-web.xml
at all.

Application assembler maps the *logical* names to runtime counterparts
with geronimo-web.xml. I'd say you should never use geronimo-web.xml
in war. Why? Because it's not in a developer role to  do the mapping,
but it's only him/her able to change the war (the war should be sealed
and untouched by anyone but developer, right?). It's an application
assembler's or a application deployer's job. They can use a separate,
external plan (geronimo-web.xml, geronimo-plan.xml, name it whatever
you want) and not change anything in your war or ear. That's one of
the goodies you can find in Geronimo (there're more, but since you've
not asked about them I won't list them here ;-)). No need to include
the runtime configuration *inside* an application since it could
eventually be deployed to different Geronimo runtime environments
where resources are named differently depending on administrator's
mood (or expertise).

Jacek

-- 
Jacek Laskowski
http://www.JacekLaskowski.pl