Btw, I am really interested in a maven2 based example, if there are any such online anywhere.
I've found a good example of Seam on Jetty with maven.
- The development cycle is a lot faster
- IDE integration is easier (just a war, no need for an ear etc)
- I don't have any classpath hell
- I can control the hibernate etc versions
Only downside is that it doesn't support EJB3, which is a pity, but a sacrifice I am more then willing to make... unless it's possible to easily run the jboss microcontainer on Jetty. Has anyone done that before?
I've been using JBoss 3 and 4 for a few years now (with and w/o Seam).
what specific deployment issues are you having?
here is an interesting article on
Building Your Own JBoss Configuration using microkernel.
Keep in mind, if you don't have access to the ejb container using this customized microkernel strategy, you will lose a lot of the container's services like local and distributed transactions, security, as well as the clustering, web services and interceptors that JBoss AS provides.
Spring and hibernate is an option as well and Seam does integrate with Spring from what I've read.
Also, EJB lite is on the way (see EJB 3.1 spec).
I am using maven to build my application and I am spoiled because I am used to the excellent maven-jetty-plugin, which allows me to do everything in a single command:
svn checkout ...myproject cd myproject mvn jetty:run-exploded
I've encountered several issues when trying to recreate the same luxury with JBoss AS:
- It simply boots to slow. I don't need clustering, web services, etc. I just need Servlets, JSF and EJB3.
- The perm gen issue was annoying, giving it more memory solved that, except that I can't really spare half a gig just for JBoss as I only got 1 gig of RAM... so windows starts swapping out memory and I lose lots of time
- Most dependencies, such as hibernate, jta, etc. need to be marked as scope provided. The version available in JBoss AS doesn't always match the version I am compiling against.
- Exploded ears are sometimes buggy in my IDE.
I would much rather deploy the things I need (Servlets, JSF, EJB3) along in my war, so I can control the version. With Jetty I am now able to do that, except for EJB3.