You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Nikola Milutinovic <Ni...@ev.co.yu> on 2004/07/12 17:00:57 UTC

Re: webapp in webapp

agarlita,dan wrote:

>Hi,
>can I make a webapp in another webapp ?
>somethig like:
>\root = myFirstApp (WEB-INF - folder)
>\root\xam\nettools\ = mySecondApp (WEB-INF -folder)
>
>whitout modify the configuration files for server, only the local xml for
>\root?
>  
>

Each web-app MUST have it's descriptor and MUST be deployed by the 
container. I'm not sure how Tomcat handles two web-apps with overlapping 
URI. In other words, URI: 
http://server.domain.com/root/xam/nettools/index.html matches both web 
applications. Is there a specification on this issue?

Nix.

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


Re: webapp in webapp

Posted by "agarlita,dan" <da...@xm-zone.com>.
:) Thank for this informations. I know that. 
with 2 different apps works. I know... But the concept and the 
ideea behind that is a little big...  Thanks for the info anyway.

Thanks,
Dag

----- Original Message ----- 
From: "Nikola Milutinovic" <Ni...@ev.co.yu>
To: "Tomcat Users List" <to...@jakarta.apache.org>
Sent: Monday, July 12, 2004 9:19 AM
Subject: Re: webapp in webapp


> agarlita,dan wrote:
> 
> >hi,
> >the http://server.domain.com/root/xam/nettools/index.html is
> >complied/interpreted by the root application,
> >but in this folder is another web-app with full "web.xml" and WEB-INF
> >folders.
> >I think it will be somethig like "Context" in "Context"
> >I try all I know on tomcat, all configuration... all
> >
> >Nothing:) I will be gratefull for any ideea
> >DAG
> >
> 
> OK, first of all, there is no such concept in Java Servlet specification 
> as "web-app in web-app", nested web apps, if you like. If you have two 
> (distinct) web applications, the should be placed in SEPARATE directory 
> hierarchies, each one deployed as if they had no dependance at all. Then 
> you can try to play with deployment, so that corresponding URIs that are 
> attached to these applications *overlap*.
> 
> Doing what you did will not do what you want - IOW, there will be only 
> one web application and the "other" will be treated as a set of files. 
> Granted, JSPs will execute, but servlets and all classes within the 
> second (deeper) WEB-INF will not be deployed or treated as a part of a 
> second WEB-INF. They will be accessable as just plain files.
> 
> If you do it "my way" you might get what you wanted, but I cannot 
> guarantee it works on other JSP/Servlet containers. I'm not sure what 
> the spec says (if anything) on the subject of overlapping deployment URI.
> 
> Guys, anyone?
> 
> Nix.
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> 

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


Re: webapp in webapp

Posted by Nikola Milutinovic <Ni...@ev.co.yu>.
agarlita,dan wrote:

>hi,
>the http://server.domain.com/root/xam/nettools/index.html is
>complied/interpreted by the root application,
>but in this folder is another web-app with full "web.xml" and WEB-INF
>folders.
>I think it will be somethig like "Context" in "Context"
>I try all I know on tomcat, all configuration... all
>
>Nothing:) I will be gratefull for any ideea
>DAG
>

OK, first of all, there is no such concept in Java Servlet specification 
as "web-app in web-app", nested web apps, if you like. If you have two 
(distinct) web applications, the should be placed in SEPARATE directory 
hierarchies, each one deployed as if they had no dependance at all. Then 
you can try to play with deployment, so that corresponding URIs that are 
attached to these applications *overlap*.

Doing what you did will not do what you want - IOW, there will be only 
one web application and the "other" will be treated as a set of files. 
Granted, JSPs will execute, but servlets and all classes within the 
second (deeper) WEB-INF will not be deployed or treated as a part of a 
second WEB-INF. They will be accessable as just plain files.

If you do it "my way" you might get what you wanted, but I cannot 
guarantee it works on other JSP/Servlet containers. I'm not sure what 
the spec says (if anything) on the subject of overlapping deployment URI.

Guys, anyone?

Nix.

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


Re: webapp in webapp

Posted by "agarlita,dan" <da...@xm-zone.com>.
hi,
the http://server.domain.com/root/xam/nettools/index.html is
complied/interpreted by the root application,
but in this folder is another web-app with full "web.xml" and WEB-INF
folders.
I think it will be somethig like "Context" in "Context"
I try all I know on tomcat, all configuration... all

Nothing:) I will be gratefull for any ideea
DAG


----- Original Message ----- 
From: "Nikola Milutinovic" <Ni...@ev.co.yu>
To: "Tomcat Users List" <to...@jakarta.apache.org>
Sent: Monday, July 12, 2004 8:00 AM
Subject: Re: webapp in webapp


> agarlita,dan wrote:
>
> >Hi,
> >can I make a webapp in another webapp ?
> >somethig like:
> >\root = myFirstApp (WEB-INF - folder)
> >\root\xam\nettools\ = mySecondApp (WEB-INF -folder)
> >
> >whitout modify the configuration files for server, only the local xml for
> >\root?
> >
> >
>
> Each web-app MUST have it's descriptor and MUST be deployed by the
> container. I'm not sure how Tomcat handles two web-apps with overlapping
> URI. In other words, URI:
> http://server.domain.com/root/xam/nettools/index.html matches both web
> applications. Is there a specification on this issue?
>
> Nix.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>


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