Java EE Containers
Overview
In Java EE mode, Pax Exam supports GlassFish, JBoss, Resin and TomEE with the following containers:
- Embedded GlassFish Container
- Hybrid GlassFish Container
- JBoss AS 7.2 Container
- JBoss Container
- Resin Container
- TomEE Container
Embedded or not?
All Java EE containers are embedded in the sense of running in the same Java VM as the test driver. The two containers for GlassFish, Embedded and Hybrid only differ in the specific way of embedding the server.
The Embedded GlassFish container is just a thin wrapper around the glassfish-embedded-all artifact which does not support OSGi. You can deploy WAR modules in this container, but you cannot provision OSGi bundles.
The Hybrid GlassFish container embeds an OSGi framework and provisions the GlassFish bundles in this framework. This container supports all features offered by a stand-alone GlassFish server. You can deploy and test hybrid applications, composed of both WAR modules and OSGi bundles.
Default Reactor Strategy
For Java EE containers, the default reactor strategy is PerSuite
. This is because most embedded server implementations do not permit to cleanly shutdown and restart the server in the same process.
Test classes should not override the default.