GlassFish v3 - The Killer Java EE 6 Appserver - Top Ten Favorites
GlassFish v3 - the killer appserver for the killer platform (Java EE 6) is out. What I like:
- Easy installation: you can use the installer or just download the ZIP and extract it. Even easier than Glassfish v2 - you had to execute an ANT target to install the domain.
- Built-in monitoring capabilities: you can monitor web applications, EJBs, JMS directly from the admin console, command line or JMX.
- Stability / high quality: Although I even tested the esoteric parts of the spec (like TransactionSynchronizationRegistry), It was really hard to find a serious bug. I filed some issues - but none of them would be show stopper in a real world project.
- Administration: You can monitor, deploy your applications and configure glassfish through the admin console, command line, direct XML editing (actually not directly supported, but works very well) and REST interface.
- Developer friendliness: GlassFish v3 is tightly integrated with Eclipse, IntelliJ and NetBeans. Incremental deployment of EJBs / JSF 2.0 / REST / JMS (EARs, EJB-JARs or WARs) takes < 300 ms on average - just by saving the class. If it takes considerably longer - your virus scanner is probably turned on :-). GlassFish v3 is embeddable - you can fire up your EJB container in few seconds.
- Lightweight nature: The
footprint is rather low. You can run midrange applications with
-Xmx512m. The full Java EE 6 server (zip) is about 75 MB. Together with
NetBeans it takes about 145 MB (Mac OS X). The EJB 3.1 container is
smaller, than 1 MB.
- Performance / Scalability: Glassfish V2 won some performance metrics. Glassfish v3 seems (I didn't compared them yet) to be as fast as V2. I already managed to connect with several thousands clients via Grizzly. During a load test we accidentally opened several thousands HTTP, Stateful Session Bean, JPA sessions with standard configuration. Glassfish v3 just worked.
- Bleeding edge: HK2, REST administration interface, update configuration, DTrace / BTrace support, JRuby, Python, PHP support.
- Hype compliance: Glassfish
v3 is (probably) the only server which you can run on Felix and Equinox
OSGi kernel. Although I successfully avoided unnecessary use of OSGi in
my projects so far - it's not KISS - I was asked about the OSGi
support. It is good to be able to answer the question with a double
"yes".
- Standard compliance: Glassfish v3 is the reference implementation of the Java EE 6. It implements all required specs pretty well.
If you need some projects to play with Glassfish v3 - most of the 34 http://kenai.com/projects/javaee-patterns/ projects were developed and tested with Glassfish v3.
(Note: Opinions expressed in this article and its replies are the opinions of their respective authors and not those of DZone, Inc.)
Tags:





Comments
Jacek Furmankiewicz replied on Thu, 2009/12/31 - 9:32am
What it's missing for real-life usage is an embedded Maven plugin, like Jetty has (i.e. the ability to run of your code without the need to create a WAR or EAR). Until GF3 has the equivalent of "mvn jetty:run" it will be at a disadvantage for Maven-based shops.
So I hope the GF3 team puts some work into the Maven plugin to bring it up to speed with what Jetty offers for rapid development.
Mark Unknown replied on Thu, 2009/12/31 - 12:38pm
9. While it can be hype, OSGi in and of itself is not. While the benefits provided by OSGi are not needed in every project, some projects are more complicated if they don't use something like OSGi.
Btw, is KISS:
1. Keep It Simple Stupid
2. Keep It Stupid Simple
3. Keep it Simple [for] Stupid [people]
Zqudlyba Navis replied on Thu, 2009/12/31 - 3:50pm
Great. Now let's see if the future version of WebSphere Application Server (WAS) with JavaEE 6 support could catch up with the competition.
My current base WAS with JavaEE 5 support takes up 4GB to install, and takes 2 minutes to start up on my local PC, just to deploy and run my 900K lines of code JavaEE app.
Henk De Boer replied on Fri, 2010/01/01 - 3:07am
in response to:
Zqudlyba Navis
Henk De Boer replied on Fri, 2010/01/01 - 3:10am
Also, does anyone know whether Glassfish V3 has or gets 'services'? Like a URL deployer?
Thomas Berger replied on Sat, 2010/01/02 - 6:44am
Henk De Boer replied on Sat, 2010/01/02 - 2:40pm
in response to:
Thomas Berger
Although I 100% agree with you on the source code package in a zip or jar that is obviously missing, I don't quite agree with the "like everyone else" part. In fact, very few projects offer a single easy to attach source code package. Until version 6.0.16 or so, Tomcat was quite a disaster too. The source code consisted out of more than 30 separate projects each with their own subdirectory containing the actual source.
Many other things, be it libraries or servers or whatever, package their source in the form of some project dir and rarely as a ready-to-attach zip of jar file.
Shaw Gar replied on Mon, 2010/01/04 - 9:40am
Reza Rahman replied on Mon, 2010/01/04 - 1:05pm
Shaw,
Personally, I don't have a great stake on either NetBeans or Eclipse. I've been using Eclipse for a while but have never really been very happy with it. I find NetBeans Java EE support to be much better, as well as NetBeans being a lot more lightweight.
Cheers,
Reza
Henk De Boer replied on Mon, 2010/01/04 - 1:54pm
Eclipse on the other hand comes with TPTP, and GEF, and EMF, and literally dozens of such things. But can I use e.g. TPTP for profiling? From the description it looks like it, but then again, it also doesn't. It appears to be some foundational library to build profilers on, it doesn't seem to -be- a profiler.
Specifically about Java EE, I get the feeling that Eclipse wants to be everything for anyone, and the Java EE support is somewhere on the list (WTP), but it isn't really a priority. WTP still doesn't know about some basic J2EE 1.4 JSP features (dynamic attributes) and you can also forget about global JSF resource bundles.
I do like Eclipse a lot for their project organization and I love it for their Java editing environment (JDT). I've heard from others who used NetBeans a lot that Eclipse is really better here, but thus lacks in the Java EE, Profiler and UML tooling departments.
Shaw Gar replied on Mon, 2010/01/04 - 9:17pm
Shaw Gar replied on Mon, 2010/01/04 - 9:30pm
Specifically, does it offer me a chance to choose 5 or 6 when creating a new project? I'm sure the answer is Yes, but just to confirm.
I'm planning to take up SCBCD 5 certification, and it's based on JEE 5. I need an environment that's right for me to practice. Thanks!
Jeremy Flowers replied on Sat, 2010/01/30 - 6:27pm
If you want to do Grails Development with Glassfish, don't take the java_ee_sdk-6-unix.sh command.
I spent ages trying to get it working.
As soon as I took the version from glassfish.dev.java.net/downloads/v3-final.html
called glassfish-v3-unix.sh
everything suddenly fell into place