Embedded Jetty (on Github)

It's only the first cut and needs quite a bit of work.

But it works.

Just for reference:

This tool allows running a single JAR file as an Jetty instance. You have full control over the JVM with such things as memory, min/max threads etc.
The system allows you to avoid jar-hell by specifying exactly what JARs you want to include.
The use of an app.properties file allows you to "attach" various classes, war files, public folders and what not to various contexts.
The system works by using a Main-Class attribute set to com.alltamasystems.ejr.EJettyRunner. This class determines various command line options, reads the app.properties and starts each of the attached resources to the various contexts. The use of an app.jars file describes the required CLASSPATH for execution.
Examples are provided for:
  • Plain Handlers (You can use these to implement filters as well)
  • Plain Servlets
  • Jersey Servlets
  • WAR files
  • Exploded WAR folders
  • Public Resource folders
It is quite opinionated regarding logging. It works out the runtime environment (or defined on the cmd line) and uses Slf4j and Log4j to provide precisely formatted output to either the console or a DailyRollingFileAppender.

See https://github.com/ZenGirl/EmbeddedJettyRepository

Sorry about accidentally pushing the Intellij files. Whoops. I'll clean that up later.

Anyone who would like to contribute, please contact me at kim at alltamasystems com.

No comments:

Post a Comment