tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Elijah Roberts <erobe...@alexandriasc.com>
Subject Solaris and Apache problem
Date Wed, 12 Apr 2000 21:00:29 GMT
I'm having a strange problem on Solaris using jdk1.2.2_05 and Apache 1.3.12 
since I upgraded to Tomcat RC1. JSP pages never return to the browser. It 
seems that when Tomcat parses a JSP file it gets stuck in a continuous loop 
while writing the .java file to be compiled. These files grow very large 
very quickly. For example here is a JSP page I created:

<%
         for (int i=0; i<10; i++)
         {
                 out.println("test1");
         }
%>
<html>
<head>
<p>test</p>
</body>
</html>
<%
         for (int i=0; i<10; i++)
         {
                 out.println("test2");
         }
%>

and here is the output in the .java file, until I stopped Tomcat:

<snip import statements>
public class _0002ftest_0002ejsptest_jsp_0 extends HttpJspBase {


     static {
     }
     public _0002ftest_0002ejsptest_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();

             // begin [file="/test.jsp";from=(0,2);to=(5,0)]

                         for (int i=0; i<10; i++)
                         {
                                 out.println("test1");
                         }
             // end
             // HTML // begin [file="/test.jsp";from=(5,2);to=(11,0)]
                 out.write("\r\n<html>\r\n<head>\r\n<p>test</p>\r\n</body>\r\n</html>\r\n");
out.write("\r\n<html>\r\n<head>\r\n<p>test</p>\r\n</body>\r\n</html>\r\n");
out.write("\r\n<html>\r\n<head>\r\n<p>test</p>\r\n</body>\r\n</html>\r\n");
out.write("\r\n<html>\r\n<head>\r\n<p>test</p>\r\n</body>\r\n</html>\r\n");
out.write("\r\n<html>\r\n<head>\r\n<p>test</p>\r\n</body>\r\n</html>\r\n");
<snip infinite repetition of last line.>

It never ends and the second scriptlet never gets written out. I am also 
using Tomcat RC1 on a windows box with JDK1.3RC1 with no problems. 
Yesterday my Solaris worked with Tomcat Beta1. To upgrade from beta to rc1 
I just copied the new /lib/*.jar file from the binary archive. Were there 
changes to the conf files that would cause this that I need to update? Any 
ideas?

Elijah Roberts
Java Consultant
eroberts@alexandriasc.com
606-816-1186 
Mime
View raw message