0

I am using Eclipse Indigo with runjettyrun plugin (latest). The webapp deploys successfully, but on non-trivial page I get a JSP custom tag compilation error.

I am getting the following JSP compilation error:

java.lang.IllegalStateException: STREAM at org.eclipse.jetty.server.Response.getWriter(Response.java:683)

I want to look at the java file that got created from the Tag file. In the stacktrace, I can see that the Tag is being compiled to a file name: xyz_Tag.java

I would like to view this java file. Any idea where I can find it?

rk2010
  • 3,481
  • 7
  • 27
  • 39

1 Answers1

1

you can instruct Jetty to keep generated java source files. There are many ways to configure this. Easiest way to do it is passing init parameter keepgenerated as true for org.apache.jasper.servlet.JspServlet in web.xml.

 <init-param>
     <param-name>keepgenerated</param-name>
     <param-value>>true</param-value>
 </init-param>

More details you can find in: http://wiki.eclipse.org/Jetty/Howto/Configure_JSP

Seshagiri
  • 728
  • 5
  • 10
  • Thanks. That link is great. I added the keepgenerated flag, but I am still not able to find my jsp's java files. I keep finding the ones created by Tomcat (from an earlier deployment attempt). – rk2010 May 01 '12 at 14:42
  • I am using runjettrun plugin for eclipse. I wonder if that is the reason I can't find Jsp's java files – rk2010 May 01 '12 at 14:42
  • I have cygwin, and using this command to find the java files: `find .. -iname '*jsp*java'` – rk2010 May 01 '12 at 14:46
  • Your link led me to this page: [http://docs.codehaus.org/display/JETTY/Temporary+Directories] Creating a "work" dir in WEB-INF dir is doing the trick. I don't know what the context attribute isn't working though. I will try to figure it sometime :) Thanks! – rk2010 May 01 '12 at 15:21