Hi Andy,
Actually, both the JSP compiler (Jasper) and javac process your JSPs.
 Jasper's compiler is really more of a pre-processor than an actual
compiler: it just converts a JSP into source code for a Java servlet, which
javac then compiles into Java bytecode.

The problem comes when the Java servlet source that's generated by Jasper is
malformed (due to errors in the JSP) and causes javac to generate errors.
 Those errors, as you noticed, refer to the locations within the generated
servlet source code instead of in the original JSP.  Internally, Jasper does
maintain source mappings between the two, though, so it should be possible
for the App Engine SDK to *always* report errors in terms of the original
JSP.

Keith

On Wed, Sep 16, 2009 at 4:12 PM, andy <[email protected]> wrote:

>
>
>  Thanks Keith.   I somewhat understand your point.  Since you say the
> JSP compiler would give the desired information is there a way to
> configure the hosted mode to use the JSP compiler instead of javac?
>
>  From the IRC chat today it was suggested that I add an issue.  The
> issue I added was
> http://code.google.com/p/googleappengine/issues/detail?id=2132.
>
>   If anyone else feels this is an issue please feel free to star the
> issue.
>
>   Thanks again.
>
> On Sep 16, 11:49 am, Keith Platfoot <[email protected]> wrote:
> > Hi Andy,
> > At this point, no.  For JSP errors generated by javac, the error will
> refer
> > to locations inside the generated servlet class, instead of inside the
> JSP
> > file it came from.  Errors from the JSP compiler, on the other hand,
> > *will*generally refer to the actual JSP file/line that caused the
> > error.
> >
> > I see that you've already created an issue in the public tracker, which
> is
> > exactly the right approach.  Incidentally, you created an issue *just
> > minutes* before I created essentially the same issue (issue
> > 2131<http://code.google.com/p/googleappengine/issues/detail?id=2131>)
> > on your behalf!  That's ok, though; I'll go ahead and mark mine as a
> > duplicate.
> >
> > Thanks for reporting this,
> >
> > Keith
> >
> > On Wed, Sep 16, 2009 at 11:23 AM, andy <[email protected]> wrote:
> >
> > >   I have been trying out Google App Engine for Java in Hosted mode
> > > and ran into something I hope someone can shed some light on.  I'm
> > > using JSP pages and when a JSP page generates an error ( either
> > > compilation or runtime ) the error message displayed contains
> > > reference to the line number in the compiled servlet not the jsp
> > > source.  For example, the following error is displayed for a simple
> > > invalid tag <% abc %>:
> >
> > > Unable to compile class for JSP
> >
> > > Generated servlet error:
> > >    [javac] C:\DOCUME~1\username\LOCALS~1\Temp
> > > \Jetty_0_0_0_0_8080_war____ut4fm1\jsp\org\apache\jsp\index_jsp.java:
> > > 53: ';' expected
> >
> > >  Is there a way to get the GAE hosted mode server to display JSP
> > > source line level error messages?
> >
> > >  Any help would be much appreciated.
> >
> > >  Andy
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/google-appengine-java?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to