You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by BugRat Mail System <to...@cortexity.com> on 2000/09/07 21:50:51 UTC

BugRat Report #82 has been filed.

Bug report #82 has just been filed.

You can view the report at the following URL:

   <http://znutar.cortexity.com:8888/BugRatViewer/ShowReport/82>

REPORT #82 Details.

Project: Tomcat
Category: Bug Report
SubCategory: New Bug Report
Class: swbug
State: received
Priority: high
Severity: critical
Confidence: public
Environment: 
   Release: 3.1 but also 3.2-beta-3
   JVM Release: 1.2.2 Solaris 
   Operating System: SunOS
   OS Release: 5.6
   Platform: x86

Synopsis: 
When running the examples, compilation from jsp to java enters an endless loop, filling the filesystem

Description:
<p>From what I gathered, when running a jsp, tomcat first processes it to a java (servlet) source file. Then it compiles this java source file to a class file, and only then it runs it.</p>
<p>What happens is that it fails on this first step.
I ran the first example (Numberguess). After a while without getting any results, I went on to see what was happening.
I found that the work subdirectory was suddenly tens of megabytes big and it kept increasing very quickly. So I performed a shutdown on tomcat.
This is what the numberguess example (_0002fjsp_0002fnum_0002fnumguess_0002ejspnumguess_jsp_0.java) looks like:</p>
</pre>
002ejspnumguess_jsp_0.java 
package jsp.num;

import javax.servlet.*;
import javax.servlet.http.*;
import javax.servlet.jsp.*;
import javax.servlet.jsp.tagext.*;
import java.io.PrintWriter;
import java.io.IOException;
import java.io.FileInputStream;
import java.io.ObjectInputStream;
import java.util.Vector;
import org.apache.jasper.runtime.*;
import java.beans.*;
import org.apache.jasper.JasperException;
import num.NumberGuessBean;


public class _0002fjsp_0002fnum_0002fnumguess_0002ejspnumguess_jsp_0 extends HttpJspBase {

    // begin [file="/jsp/num/numguess.jsp";from=(11,0);to=(11,72)]
    // end
    static {
    }
    public _0002fjsp_0002fnum_0002fnumguess_0002ejspnumguess_jsp_0( ) {
    }

    private static boolean _jspx_inited = false;

    public final void _jspx_init() throws JasperException {
    }

    public void _jspService(HttpServletRequest request, HttpServletResponse  response)
        throws IOException, ServletException {

        JspFactory _jspxFactory = null;
        PageContext pageContext = null;
        HttpSession session = null;
        ServletContext application = null;
        ServletConfig config = null;
        JspWriter out = null;
        Object page = this;
        String  _value = null;
        try {

            if (_jspx_inited == false) {
                _jspx_init();
                _jspx_inited = true;
            }
            _jspxFactory = JspFactory.getDefaultFactory();
            response.setContentType("text/html;charset=8859_1");
            pageContext = _jspxFactory.getPageContext(this, request, response,
                        "", true, 8192, true);

            application = pageContext.getServletContext();
            config = pageContext.getServletConfig();
            session = pageContext.getSession();
            out = pageContext.getOut();

            // HTML // begin [file="/jsp/num/numguess.jsp";from=(0,0);to=(9,0)]
                out.write("<!--\r\n  Copyright (c) 1999 The Apache Software Foundation.  All rights \r\n  reserved.\r\n\r\n  Number Guess Game\r\n  Written by Jason Hunter <ja...@kasoftware.com>, CTO, K&A Software\r\n  http://www.servlets.com\r\n-->\r\n\r\n");
out.write("<!--\r\n  Copyright (c) 1999 The Apache Software Foundation.  All rights \r\n  reserved.\r\n\r\n  Number Guess Game\r\n  Written by Jason Hunter <ja...@kasoftware.com>, CTO, K&A Software\r\n  http://www.servlets.com\r\n-->\r\n\r\n");
out.write("<!--\r\n  Copyright (c) 1999 The Apache Software Foundation.  All rights \r\n  reserved.\r\n\r\n  Number Guess Game\r\n  Written by Jason Hunter <ja...@kasoftware.com>, CTO, K&A Software\r\n  http://www.servlets.com\r\n-->\r\n\r\n");
out.write("<!--\r\n  Copyright (c) 1999 The Apache Software Foundation.  All rights \r\n  reserved.\r\n\r\n  Number Guess Game\r\n  Written by Jason Hunter <ja...@kasoftware.com>, CTO, K&A Software\r\n  http://www.servlets.com\r\n-->\r\n\r\n");
out.write("<!--\r\n  Copyright (c) 1999 The Apache Software Foundation.  All rights \r\n  reserved.\r\n\r\n  Number Guess Game\r\n  Written by Jason Hunter <ja...@kasoftware.com>, CTO, K&A Software\r\n  http://www.servlets.com\r\n-->\r\n\r\n");

</pre>
<p>
And it repeats this last line to the end of the now 76 Mb java source file !!!
Exactly the same happens to the other examples. That last line gets repeated somewhere in the middle of the compilation of the jsp to java source.
</p>
<p>
The problem seems to be just with the compilation from jsp to java since the servlets seem to run fine.
I tried tomcat3.2-beta-3 but the same thing happens
I ran the same tomcat under linux without this problem.
With jswdk-1.0.1 this doesn't happen in both systems. This is what I am using now. I was trying to migrate to tomcat but until this serious bug gets solved, I can't.
I had java version "1.2.2" Solaris VM (build Solaris_JDK_1.2.2_05, native threads, sunwjit) but I upgraded to 1.2.2_06 which is the latest, together with all the recomended patches, but to no avail.
</p>
<p>
Any ideas ?
Thanks,
Carlos.
</p>