Tailored Geronimo assembly with „Spring Application“ deployment

GasWerk LogoGeronimo is a Open Source (Apache License) full blown application server. On the homepage it is possible to download two versions – the full Java EE stack appserver and a smaller assembly only with either tomcat or jetty.

Now there is another assembly available at http://gaswerk.sourceforge.net – a „minimal you just get jms“ assemlby. This is specially interesting for those wanting to move out the JMS server to another machine, or want to create a JMS cluster.

But, the most interesting assembly surely is the spring deployment server. This Geronimy assembly allows you to deploy „spring  applications“ – packaged as jars –  providing a special bootstrap configuration in the META-INF folder in the jar.

Configuring spring beans with properties

Spring offers a PropertyPlaceholderConfigurer postprocessor bean that replaces any bean property values in the configuration at runtime. This bean can read properties from within the classpath or directly from the filesystem. If you turn on searching for properties in the system environment you can even use system properties to locate the property files (like user.home directory).

This is a code snippet I often need…