users@glassfish.java.net

Re: Compiling JSP is slow on v3

From: <glassfish_at_javadesktop.org>
Date: Wed, 08 Sep 2010 11:48:58 PDT

> I don't get it. Isn't that exactly what happens when
> I copy a new version of my EAR file to the autodeploy
> directory? When I do, [i]each[/i] JSP has a sloow
> startup (and is quick on a second request).
>
Yea, guess that is the same as an undeploy and deploy. I am used to do everything with asadmin. :-)

>
> If I understand this correctly, then only the [i]very
> first[/i] compilation would be slow, and [i]only[/i]
> after a restart of Glassfish. In other words.
> compiling another JSP should be faster than compiling
> the first JSP. I don't think I have seen that
> phenomenon. Or am I missing something?
>
But have you looked at the numbers? In particular, the C numbers on the first compilation is painfully slow, but is subsequent compilations are much faster. I thought that was your complain.

> > Maybe I should also turn off validation in xml
> parsing.
>
> Well... my IntelliJ IDEA checks the JSP code on the
> fly, so if that's a big time-gobbler then perhaps I
> don't need another check... On the other hand, I
> guess we will get more informative error messages
> with xml parsing on, if there's a problem with a JSP?
> If so, that would save a lot of trouble and
> head-scratching, right?

The JSP page will be validated only if it is in xml syntax. For standard syntax, xml validation applies only to parsing the tld and web,xml files.

I thought validation is on by default in V3. I just discovered it is actually off by default. Our intention has been to make it on by default, but now I afraid if I do that, the compilation would be even slower!
[Message sent by forum member 'kchung']

http://forums.java.net/jive/thread.jspa?messageID=482117