Does jasper have an architecture goal to run in other Servlet Containers?
I ask because I am working on a Servlet/JSP Container, and the JSP portion
(a Servlet) has been kept separate for this exact reason. We would like our
JSP implementation to be able to run in any Servlet Container, and we would
like to run other JSP implementations in our Servlet Container.
The obvious difficulty (and the reason for this message) is obtaining:
-classpath information
-classloader information
-file system path to the JSP
-many other pieces of information
It would be great if the JSP spec detailed where to put this information,
i.e., in the request under known attribute names, but since this is not
currently in place, i am interested in other options.
Options I see:
1. All Servlet/JSP implementations using common:
a) attribute storage (i.e., the request)
b) attribute names (i.e., javax.servlet.jsp.classpath)
This is probably a bit of a pipe dream since JSP implementations may expose
attributes in different places.
2. Compile a list that details where attributes are stored (it may be
several different places), and what their names are. Then, to achive
pluggability, a filter could be written which maps the Servlet Container's
attribute name/value pairs to the name value pairs the JSP implementation is
expecting. This will be slower (a filter has to run for each request), and
a bit of a hack, but it may be more acheivable then option 1.
any thoughts?
Tim Julien
HP Middleware