cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Eric Fesler" <>
Subject C2 - JSPGenerator and jsp:include
Date Fri, 19 Oct 2001 08:55:52 GMT


I'm having some trouble working with the JSPGenerator.

I'm using a JSP to generate the XML representation of an session resident
object. However, because this object presents some recursive
characteristics, I use the tag <jsp:include>.

The JSP itself works properly. However, when I'm using this JSP as a
generator for Cocoon, I've got the following error:

I've looked at the source (both Tomcat and Cocoon) and it is obvious that it
could not work.
In org.apache.cocoon.components.jsp.JSPEngineImpl, Cocoon wraps the request
in a MyServletRequest implementing HttpServletRequest.
However, when working with include, Tomcat expects a request of the class

So it generates a ClassCastException.

Any idea how to solve that or how to work around that?

Maybe there is another solution than using the JSPGenerator but the object I
want to render is create by a web application. So I've embedded Cocoon in
that application and I pass the object I want to render to Cocoon within the

I don't want to create an xml file and then call Cocoon because the
application is aimed to be used by a lot of concurrent user and I prefer to
work with objects in memory rather than written in a file.

Thanks for help,


P.S.: I'm using Tomcat 3.2.3 and Cocoon 2

Please check that your question has not already been answered in the
FAQ before posting. <>

To unsubscribe, e-mail: <>
For additional commands, e-mail: <>

View raw message