On Fri, Apr 11, 2014 at 3:41 PM, Mikolaj Rydzewski <m...@ceti.pl> wrote:
> On 11.04.2014 15:31, André Warnier wrote:
>
>> As far as I first understand such things, each of these JSP's gets
>> compiled into a servlet, and the code of that servlet is held in
>> memory for an extended period of time, even if unused at any
>> particular moment. So this is 16000 servlets probably coexisting
>> (un-)happily inside that JVM. No wonder..
>
>
> I'm pretty sure that's the problem.
> Servlets generated from JSPs contain a bunch of println statements and logic
> dependant on any tag libraries beign used.
> They all will reside in memory for the lifetime of application.
> For that huge number of pages I strongly recommend using a templating engine
> (there are plenty of them).

JSP _is_ a templating mechnism. In what way do you expect another
templating mechanism to help here? All the strings (among other stuff)
need to be stored somewhere in memory anyway.

I think André is on to something when he points to GC.  With that
large number of classes I would try to increase permanent size with
-XX:MaxPermSize. Before that an attempt with -Xnoclassgc might be
worthwhile because that will tell you if permanent size runs out of
space and an increase is in order. And then of course GC logging or
monitoring via jvisualjm and similar tools is also a good idea.

Kind regards

robert


-- 
[guy, jim].each {|him| remember.him do |as, often| as.you_can - without end}
http://blog.rubybestpractices.com/

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to