"Costin Manolache" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] On 3/4/06, Remy Maucherat <[EMAIL PROTECTED]> wrote: >> The only solution is to forbid >> scriptlets (or as an option use a processing when a page does not >> contain scriptlets - and of course, rewrite a significant amount of >> Jasper - way cool :D), in which case compilation is not needed, and we >> can simply execute the nodes (memory is saved by optionally discarding >> the nodes between requests). > >Why ? It could as well save all static content in a separate file ( I >remember this was implemented at least in part ), and instead of >generating the strings in the class, use >a cache that manages the string table. >
The Jasper with 3.3 has this as an option. Since it's main use was to shrink the size of the _jspservice method, and Jasper2 has a better approach to this, it was dropped in Jasper2. Also, in 3.3 Jasper, the static text object is a static object in the class, so you don't get any memory benifits from using it. I'm also with Remy on this that almost all users would rather trade memory for speed on this issue. However, if you want to make it an optional behavior for Jasper to store the static text as either a serialized char [][] as in TC 3.3, or ResourceBundle, by all means, knock yourself out ;-). >That would be more flexible than this patch - and allow more control >over how much memory is used. Well - with all the APR and sendfile you >could even try to send large chunks of static content from disk - not >sure what's the performance benefits in the static servlet for >example. > In most non-example JSPs, there really aren't many big blocks of static text to sendfile. They tend to look more like: <c:forEach items="${itemList.items}" var="foo"> <tr><td>${foo.name}</td><td>${foo.price}</td><td>${foo.available}</td></tr> </c:forEach> --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]