We distribute an application with a small, embedded servlet container. We
let people create their own JSP pages in that container, and they have to
write java snippets to get at our API in their pages. This is fine, except
that 1) it requires them to know Java, and 2) it requires that they have a
JDK on the system, instead of just a JRE, to compile the pages. Or else it
requires that they put a copy of tools.jar on the path, which brings its own
problems.
I'd dearly love to get away from forcing my customers to write java code to
do anything useful.
What would be great is to switch to some system where they could add
html-like tags into the pages, and the container would be smart enough to
parse the tags and replace them with dynamic data.
We looked at Struts and tag libraries a few years ago, but it was way too
complicated. We looked at FreeMarker, which is closer to what we want, but
found it a bit limited (at least it was a couple years ago).
What are the best choices out there for doing this kind of thing?
Some of our competitors have their app return XML, which is then transformed
to web pages by XSLT. This is just plain dog slow, though.
Raymond DeCampo - 13 Jan 2006 03:16 GMT
> We distribute an application with a small, embedded servlet container. We
> let people create their own JSP pages in that container, and they have to
[quoted text clipped - 19 lines]
> Some of our competitors have their app return XML, which is then transformed
> to web pages by XSLT. This is just plain dog slow, though.
Sounds like you should write your own custom tags and distribute them.
Another option would be to look into interpreted templating engines like
Velocity, Tea (or Kettle, I can't remember, from Disney of all places),
etc. Since they are not transformed into Java classes there is no
compiling.
HTH,
Ray

Signature
This signature intentionally left blank.
Roedy Green - 13 Jan 2006 03:36 GMT
On Fri, 13 Jan 2006 03:16:43 GMT, Raymond DeCampo
<nospam@twcny.rr.com> wrote, quoted or indirectly quoted someone who
said :
>> What are the best choices out there for doing this kind of thing?
See http://mindprod.com/jgloss/freemarker.html
It is somewhat simpler than other tag embedders.

Signature
Canadian Mind Products, Roedy Green.
http://mindprod.com Java custom programming, consulting and coaching.
Thomas Hawtin - 13 Jan 2006 08:25 GMT
> We distribute an application with a small, embedded servlet container. We
> let people create their own JSP pages in that container, and they have to
[quoted text clipped - 3 lines]
> requires that they put a copy of tools.jar on the path, which brings its own
> problems.
1) You could give them JSP tags to play with. Although if you want them
to do stuff that requires programming, dressing it up in an even worse
syntax wont help.
2) IIRC, Tomcat comes with a compiler and does not require a JDK.
Tom Hawtin

Signature
Unemployed English Java programmer
http://jroller.com/page/tackline/
Chris - 13 Jan 2006 16:51 GMT
> 2) IIRC, Tomcat comes with a compiler and does not require a JDK.
Is this true? That would solve some problems. I can't find any reference to
it in the docs, though. Do you have a pointer?
Thomas Hawtin - 14 Jan 2006 18:25 GMT
>>2) IIRC, Tomcat comes with a compiler and does not require a JDK.
>
> Is this true? That would solve some problems. I can't find any reference to
> it in the docs, though. Do you have a pointer?
"JDT used to compile JSP pages - The Eclipse JDT Java compiler is now
used to perform JSP java source code compilation."
-- http://tomcat.apache.org/tomcat-5.5-doc/jasper-howto.html
The setup requires only a JRE.
Tom Hawtin

Signature
Unemployed English Java programmer
http://jroller.com/page/tackline/