Website in a jar?

March 10th, 2006 by Hen

I’ve got a little tool called ReportRunner that is currently rather tricky to use - as you have to grab the jar, create the configuration files and get the exploded webapp; ie) lots of jsp and javascript etc.

I’m not too concerned with the config; but does anyone have any thoughts on how better to do the small web wizard? I’d like it to be in the jar if possible - currently I’m slowly migrating the jsp to velocity - but other ideas would be welcomed.

3 Responses to “Website in a jar?”

  1. Chris Nokleberg Says:

    I would use an embedded Jetty server and FreeMarker/Velocity templates. If you use something like JarJar (jarjar.sf.net) you could bundle everything into a single jar runnable via “java -jar rr.jar”

  2. Geert Bevin Says:

    Check out the Winstone Servlet Container (http://winstone.sourceforge.net/) it has got direct support for putting everything inside one jar and running your application from a single jar.

  3. Tim Vernum Says:

    You could always try using slim [1] to render the JSPs rather than converting them to velocity.
    They may need some tweaking, (or maybe a lot of tweaking depending on how well they’ve been written) but it’s almost certainly less work than converting them to velocity or freemarker.

    [1] http://www.adjective.org/slim/