You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by Zhenxin wang <zh...@docomolabs-usa.com> on 2002/08/06 22:09:04 UTC

contexts in server.xml and directories under webapps

Normally, each context in server.xml file has a corresponding directory under webapps, and vice versa.
However, when I deployed a app under webapps directory with the help of the manager app, I noticed that there is no change to server.xml. When I restarted the server, the newly deployed app is picked up and become accessible as normal. Looks like as long as the app directory is there, it does not matter much wether the context is in the server.xml file or not.

My question is that is it true that Tomcat looks for deployed apps/contexts under webapps directory and server.xml only provides additional information for the apps/contexts?

An brief explanation on the relationship between these two entities will be greatly appreciated.

Thanks!

--Zhenxin Wang
DoCoMo Labs USA

Re: contexts in server.xml and directories under webapps

Posted by Glenn Nielsen <gl...@mail.more.net>.
I have a request.

Please do not post your questions to both the tomcat-user and tomcat-dev
lists.  The types of questions you have been asking are more appropriate to the
tomcat-user list, please ask your questions there.

Please follow the guidelines at:

http://jakarta.apache.org/site/mail.html

when posting your questions.

Thanks,

Glenn

Zhenxin wang wrote:

> Normally, each context in server.xml file has a corresponding directory under webapps, and vice versa.
> However, when I deployed a app under webapps directory with the help of the manager app, I noticed that there is no change to server.xml. When I restarted the server, the newly deployed app is picked up and become accessible as normal. Looks like as long as the app directory is there, it does not matter much wether the context is in the server.xml file or not.
> 
> My question is that is it true that Tomcat looks for deployed apps/contexts under webapps directory and server.xml only provides additional information for the apps/contexts?
> 
> An brief explanation on the relationship between these two entities will be greatly appreciated.
> 
> Thanks!
> 
> --Zhenxin Wang
> DoCoMo Labs USA
> 
> 


-- 
----------------------------------------------------------------------
Glenn Nielsen             glenn@more.net | /* Spelin donut madder    |
MOREnet System Programming               |  * if iz ina coment.      |
Missouri Research and Education Network  |  */                       |
----------------------------------------------------------------------



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: contexts in server.xml and directories under webapps

Posted by Zhenxin wang <zh...@docomolabs-usa.com>.
The manager app (via calling StandardHost.install(..)) did create the
directory and everything under it.
On restart, it is still there and accessible by clients.

--Zhenxin
----- Original Message -----
From: "Craig R. McClanahan" <cr...@apache.org>
To: "Tomcat Developers List" <to...@jakarta.apache.org>
Cc: "Tomcat Users List" <to...@jakarta.apache.org>
Sent: Tuesday, August 06, 2002 1:33 PM
Subject: Re: contexts in server.xml and directories under webapps


>
>
> On Tue, 6 Aug 2002, Zhenxin wang wrote:
>
> > Date: Tue, 6 Aug 2002 13:09:04 -0700
> > From: Zhenxin wang <zh...@docomolabs-usa.com>
> > Reply-To: Tomcat Developers List <to...@jakarta.apache.org>
> > To: Tomcat Users List <to...@jakarta.apache.org>
> > Cc: Tomcat Developers List <to...@jakarta.apache.org>
> > Subject: contexts in server.xml and directories under webapps
> >
> > Normally, each context in server.xml file has a corresponding directory
under webapps, and vice versa.
> > However, when I deployed a app under webapps directory with the help of
the manager app, I noticed that there is no change to server.xml. When I
restarted the server, the newly deployed app is picked up and become
accessible as normal. Looks like as long as the app directory is there, it
does not matter much wether the context is in the server.xml file or not.
> >
> > My question is that is it true that Tomcat looks for deployed
apps/contexts under webapps directory and server.xml only provides
additional information for the apps/contexts?
> >
> > An brief explanation on the relationship between these two entities will
be greatly appreciated.
> >
>
> In Tomcat 4.0, webapps deployed via manager are transient, and there is no
> mechanism to update server.xml so that the apps are there next time.
> Tomcat 4.1 has such logic (primarily to support the admin webapp) -- I'm
> not sure offhand whether the act of installing an app via manager actually
> triggers the writing though.
>
> > Thanks!
> >
> > --Zhenxin Wang
> > DoCoMo Labs USA
>
> Craig
>
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> For additional commands, e-mail:
<ma...@jakarta.apache.org>
>
>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: contexts in server.xml and directories under webapps

Posted by Zhenxin wang <zh...@docomolabs-usa.com>.
The manager app (via calling StandardHost.install(..)) did create the
directory and everything under it.
On restart, it is still there and accessible by clients.

--Zhenxin
----- Original Message -----
From: "Craig R. McClanahan" <cr...@apache.org>
To: "Tomcat Developers List" <to...@jakarta.apache.org>
Cc: "Tomcat Users List" <to...@jakarta.apache.org>
Sent: Tuesday, August 06, 2002 1:33 PM
Subject: Re: contexts in server.xml and directories under webapps


>
>
> On Tue, 6 Aug 2002, Zhenxin wang wrote:
>
> > Date: Tue, 6 Aug 2002 13:09:04 -0700
> > From: Zhenxin wang <zh...@docomolabs-usa.com>
> > Reply-To: Tomcat Developers List <to...@jakarta.apache.org>
> > To: Tomcat Users List <to...@jakarta.apache.org>
> > Cc: Tomcat Developers List <to...@jakarta.apache.org>
> > Subject: contexts in server.xml and directories under webapps
> >
> > Normally, each context in server.xml file has a corresponding directory
under webapps, and vice versa.
> > However, when I deployed a app under webapps directory with the help of
the manager app, I noticed that there is no change to server.xml. When I
restarted the server, the newly deployed app is picked up and become
accessible as normal. Looks like as long as the app directory is there, it
does not matter much wether the context is in the server.xml file or not.
> >
> > My question is that is it true that Tomcat looks for deployed
apps/contexts under webapps directory and server.xml only provides
additional information for the apps/contexts?
> >
> > An brief explanation on the relationship between these two entities will
be greatly appreciated.
> >
>
> In Tomcat 4.0, webapps deployed via manager are transient, and there is no
> mechanism to update server.xml so that the apps are there next time.
> Tomcat 4.1 has such logic (primarily to support the admin webapp) -- I'm
> not sure offhand whether the act of installing an app via manager actually
> triggers the writing though.
>
> > Thanks!
> >
> > --Zhenxin Wang
> > DoCoMo Labs USA
>
> Craig
>
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
> For additional commands, e-mail:
<ma...@jakarta.apache.org>
>
>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: contexts in server.xml and directories under webapps

Posted by Ian Darwin <ia...@darwinsys.com>.
On August 6, 2002 04:33 pm, you wrote:
> In Tomcat 4.0, webapps deployed via manager are transient, and there is no
> mechanism to update server.xml so that the apps are there next time.
> Tomcat 4.1 has such logic (primarily to support the admin webapp) -- I'm
> not sure offhand whether the act of installing an app via manager actually
> triggers the writing though.

It doesn't, and I hope it stays that way. I like the Admin app (not Manager)
having a clearly labelled "COMMIT CHANGES" button before it loses all your
formatting and comments from your server.xml :-).

At present, the story is: use Manager for simple things like testing deployment,
triggering reload, etc.  Use Admin for a more complete administration tool.


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: contexts in server.xml and directories under webapps

Posted by "Craig R. McClanahan" <cr...@apache.org>.

On Tue, 6 Aug 2002, Zhenxin wang wrote:

> Date: Tue, 6 Aug 2002 13:09:04 -0700
> From: Zhenxin wang <zh...@docomolabs-usa.com>
> Reply-To: Tomcat Developers List <to...@jakarta.apache.org>
> To: Tomcat Users List <to...@jakarta.apache.org>
> Cc: Tomcat Developers List <to...@jakarta.apache.org>
> Subject: contexts in server.xml and directories under webapps
>
> Normally, each context in server.xml file has a corresponding directory under webapps, and vice versa.
> However, when I deployed a app under webapps directory with the help of the manager app, I noticed that there is no change to server.xml. When I restarted the server, the newly deployed app is picked up and become accessible as normal. Looks like as long as the app directory is there, it does not matter much wether the context is in the server.xml file or not.
>
> My question is that is it true that Tomcat looks for deployed apps/contexts under webapps directory and server.xml only provides additional information for the apps/contexts?
>
> An brief explanation on the relationship between these two entities will be greatly appreciated.
>

In Tomcat 4.0, webapps deployed via manager are transient, and there is no
mechanism to update server.xml so that the apps are there next time.
Tomcat 4.1 has such logic (primarily to support the admin webapp) -- I'm
not sure offhand whether the act of installing an app via manager actually
triggers the writing though.

> Thanks!
>
> --Zhenxin Wang
> DoCoMo Labs USA

Craig


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: contexts in server.xml and directories under webapps

Posted by "Craig R. McClanahan" <cr...@apache.org>.

On Tue, 6 Aug 2002, Zhenxin wang wrote:

> Date: Tue, 6 Aug 2002 13:09:04 -0700
> From: Zhenxin wang <zh...@docomolabs-usa.com>
> Reply-To: Tomcat Developers List <to...@jakarta.apache.org>
> To: Tomcat Users List <to...@jakarta.apache.org>
> Cc: Tomcat Developers List <to...@jakarta.apache.org>
> Subject: contexts in server.xml and directories under webapps
>
> Normally, each context in server.xml file has a corresponding directory under webapps, and vice versa.
> However, when I deployed a app under webapps directory with the help of the manager app, I noticed that there is no change to server.xml. When I restarted the server, the newly deployed app is picked up and become accessible as normal. Looks like as long as the app directory is there, it does not matter much wether the context is in the server.xml file or not.
>
> My question is that is it true that Tomcat looks for deployed apps/contexts under webapps directory and server.xml only provides additional information for the apps/contexts?
>
> An brief explanation on the relationship between these two entities will be greatly appreciated.
>

In Tomcat 4.0, webapps deployed via manager are transient, and there is no
mechanism to update server.xml so that the apps are there next time.
Tomcat 4.1 has such logic (primarily to support the admin webapp) -- I'm
not sure offhand whether the act of installing an app via manager actually
triggers the writing though.

> Thanks!
>
> --Zhenxin Wang
> DoCoMo Labs USA

Craig


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>