tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Reinhard Nägele <reinhard.naeg...@mgm-edv.de>
Subject Re: war deployment and jsp pre-compilation
Date Fri, 11 Jul 2003 12:40:03 GMT
I'm afraid, I wasn't clear enough explaining the issue. First, let's 
assume, I do not pre-compile my JSPs and deploy the war with the manager 
app.  Upon the first request, Tomcat will go about and compile the JSPs 
to the working directory. As there is no context entry in the 
server.xml, Tomcat will use its default working directory.

Now, I'd like to pre-compile the JSPs including only the compiled JSP 
classes in the war file. This means that Tomcat would have to load the 
JSP classes directly from the war file instead of from its working 
directory. Can this be done?

I hope the issue is clear now.

Thanks for any insight.

Reinhard


Jacob Kjome wrote:

> At 11:05 AM 7/11/2003 +0200, you wrote:
>
>> Thanks, but that's not the problem. I know how to use Ant and jspc. 
>> The question is whether/how I can tell Tomcat to load pre-compiled 
>> JSPs from my war file which is not unpacked as I deploy with 
>> unpackWars set to false.
>
>
> The work directory is Tomcat's temp directory.  It is the one place 
> that is guaranteed to allow files to be written for a webapp.  It has 
> nothing to do with your issue.  Actually, I'm not really sure what you 
> are talking about.  Precompiled jsp's added to the webapp are just 
> servlets.  You don't need to use File IO to load servlets.  They 
> should be able to run out of a .war file just as they can from a 
> directory.  You specify this using <servlet> and <servlet-mapping> 
> entries in in web.xml just like any other servlet.  Are you saying 
> that this works for you when the .war is unpacked, but not when it 
> isn't?  That would be truly odd.  you'll need to explain why you think 
> things aren't working from a .war file first before anyone can help 
> you here.
>
> Jake
>
>> Any ideas?
>>
>> Reinhard
>>
>>
>> Johannes Fiala wrote:
>>
>>> Hi Reinhard,
>>>
>>> Using TC 4.1.24+ you can use ant to first run JspC and deploy the 
>>> resulting WAR using the manager app.
>>>
>>> You can find more info here:
>>> http://www.fwd.at/tomcat/buildmanagement-using-ant-howto.html
>>>
>>> Johannes
>>>
>>>
>>>
>>>
>>> Reinhard Nägele <reinhard.naegele@mgm-edv.de> 10.07.2003 15:38
>>> Please respond to
>>> "Tomcat Users List" <tomcat-user@jakarta.apache.org>
>>>
>>>
>>> To
>>> tomcat-user@jakarta.apache.org
>>> cc
>>>
>>> Subject
>>> war deployment and jsp pre-compilation
>>>
>>>
>>>
>>>
>>>
>>>
>>> We deploy our application as war file with the manager. "unpackWars" 
>>> is set to false. Is it possible to deploy pre-compiled JSPs with 
>>> this approach? I guess this would imply that we'd have to have a 
>>> context.xml in our war file specifying that Tomcat should load the 
>>> compiled JSP classes from the war file instead of from its working 
>>> directory. Can this be done?
>>>
>>> Reinhard
>>>
>>>
>>>
>>> ---------------------------------------------------------------------
>>> 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
>
>
>
> ---------------------------------------------------------------------
> 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


Mime
View raw message