I want to server a JSP page that is stored in a database as a blob. So if a request comes in at the url http://mydomain.com/app/list.jsp I know to go to the DB to retrieve the resource list.jsp.
I am using spring and tiles, so have adispatcher servlet and controllers set up and working in traditional sense. Would this be similar in principle to the resource servlet that spring web has to serve javascript files and messages from within jar?
Note that the JSPs would not just be static HTML, I will have beans (model attributes) associated with the page, so will still want to use EL to query the bean.
Cheers
Because JSPs are part of the J2EE standard, you can deploy JSPs on a variety of platforms, including WebLogic Server.
The Java statements are placed inside the _jspService() method of the translated servlet as "it is". Scriptlets form the program logic. JSP Expression <%= .... > : used to evaluate a single Java expression to obtain a value. The Java expression is placed inside a out.
"JSP technology is considered to be a deprecated presentation technology for JavaServer Faces."
JSP loading and compiling is implemented in the servlet container. There are two approaches I can think of using for making this feature possible:
In both scenarios you have to worry about memory leaks for unloaded classes, especially if any of your code uses ThreadLocals or other static variables. The normal JSP loaders already suffer from problems if you unload WARs or recompile JSPs at runtime. This is due to limitations in Java and is not easily solved (depending on which JDK is used). I would recommend never, or very rarely, changing JSPs without restarting the server unless you can't avoid it.
See for example Eval taglib from Coldtags suite: http://www.servletsuite.com/servlets/evaltag.htm
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With