tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Edoardo Causarano <edoardo.causar...@gmail.com>
Subject Re: Creating /WEB-INF folders for virtualhosts
Date Sat, 19 Aug 2006 12:03:51 GMT
The host appbase attribute specifies the directory where the wars  
(exploded or left intact) are stored and is not a documentroot in the  
apache httpd sense. The latter would be the ROOT.war webapp to which  
root relative paths unmatched by any other war prefix resolve.

Distribution of object instances across multiple contexts belongs to  
the J2EE container problem space (JBoss, WebSphere, Geronimo, JonAS,  
etc...) while Tomcat is a web container (a component of J2EE). You  
could dump some singletons in the shared classloader (classes loaded  
from the "shared" library path) but then you must be careful about  
reference counting in these classes or you'll have leaks (in the  
sense that references aren't really released and the gc won't reclaim  
the objects) and eventually eat all the jvm memory; suggestion: use  
lifecycle listeners in the webapp.

You could set the crossContext attribute to "true" and do as in  
http://forum.java.sun.com/thread.jspa? 
threadID=580846&messageID=2956369 but not unless you have total  
control on the server and you can still do forwards in struts without  
relaxing webapp isolation.

Ciao,
e

On 19/ago/06, at 05:55GMT+02:00, John Hinton wrote:

> John Hinton wrote:
>> Seems I have everything running up to the point of a test.jsp file  
>> being excuted within a virtualhost's user directory.
>>
>> If I understand correctly, there should be a WEB-INF directory in  
>> the virtualhost root directory, with a web.xml document there.
>>
>> My snag.. is there a built in way to create this directory and the  
>> info it should contain?
>>
>> If I am to create this directory, what permissions should it have?  
>> And what about additional classes and librarys, such are are in  
>> the default server directory?
>>
>> A good example of the web.xml file would be helpful as well.
> OK, perhaps I should start over..
>
> I am a server admin and have no experience with jsp. I need to run  
> this system especially for a virtual host client.
>
> I seem to have the basics of installation working as I can get to  
> the manager pages. However when I try to open a test.jsp file in  
> that client's virtualhost public_html directory, I get the  
> following error.
>
>
>  HTTP Status 404 - /test.jsp
>
> ---------------------------------------------------------------------- 
> --
>
> *type* Status report
>
> *message* _/test.jsp_
>
> *description* _The requested resource (/test.jsp) is not available._
>
> ---------------------------------------------------------------------- 
> --
>
>
>      Apache Tomcat/5.5.9
>
>
> My OS is CentOS 3.6 in this case. Could someone please try to help  
> me through this? Actually, I'm not really even sure what
>
> The requested resource (/test.jsp) is not available means? Is this  
> a path to test.jsp problem or a notice that for some reason it  
> can't be run?
>
> Thanks,
> John Hinton
>
> ---------------------------------------------------------------------
> To start a new topic, e-mail: users@tomcat.apache.org
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message