DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUGĀ·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=39309>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED ANDĀ·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=39309

           Summary: tomcat can't compile big jsp, hitting a compiler limit
           Product: Tomcat 5
           Version: 5.5.16
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Jasper
        AssignedTo: tomcat-dev@jakarta.apache.org
        ReportedBy: [EMAIL PROTECTED]


Tomcat is unable to compile a JSP which has a too long section of pure html in 
it.

Because during jsp -> java operation jasper is creating 1 method per enclosing 
tag (+one jsp service method for root content), jasper is sometimes unable to 
compile a jsp. This happens because jasper splits the JSP at line break and 
converts them to out.print("......\n"); Nowhere in jsp specs is a limit 
mentioned on the number of lines. However, each out.println() is using a bit 
of code space, and you finally end up hitting the compiler limit of 64k 
maximum size of code for a method.

and you get this:
The code of method _jspService(HttpServletRequest, HttpServletResponse) is 
exceeding the 65535 bytes limit
        at 
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:84)
        at 
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:328)
        at 
org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:413)
        at org.apache.jasper.compiler.Compiler.compile(Compiler.java:297)
        at org.apache.jasper.compiler.Compiler.compile(Compiler.java:276)
        at org.apache.jasper.compiler.Compiler.compile(Compiler.java:264)

one solution would be to rerun the .java generator when such a compilation 
error with an hint telling it to split this method's content in 2 or more 
methods.

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to