Site icon Antonio's Blog

O Application Servers, Where Art Thou?

With Java EE 6 and GlassFish v3 out, it is time to take a little break and look at the application server world. J2EE 1.2 was created in 1999, that’s 10 years ago. The application server market at the time was completely different of the one today. There was Weblogic and Websphere, other proprietary application servers (not following J2EE) and no open source application server. Today, it is a completely different story.

The application servers’ world has changed so much in the last 10 years, but people still have in mind the heavyweight server that takes huge amount of RAM, disk space and takes ages to start (being completely useless for agile developers who need to test and code quickly and often). So let’s focus on some application servers  (Geronimo, GlassFish, JBoss, Jetty, JOnAS, Resin, Tomcat, Weblogic and Webspere) and check some parameters.

The benchmark

Disclaimer :This is not a real benchmark !

In this little test I’m just concerned about the usability of an application server for a developer. The idea is to download it, install it, start it and take some measurements (size of download, ease of installation, size of disk, startup time, size of RAM…). That’s all. No deployment of an application, no fancy twists to gain performance…. Because some of these application servers are resource consuming, I’m doing all my tests on a Windows XP virtual machine (running on Virtual Box 3.1). It is a fresh install of Windows XP sp3 with 1Gb of RAM and not too many software installed (I had to install Avast but). So when I boot there are 27 processes running and using 230 Mb of RAM (leaving 770 Mb free). Virtualizing can be slower, so keep in mind that startup time can be a bit faster that what I’m giving you here. I use JDK 1.6.0_17 (when it’s not bundled with the server). No optimization at all is made (I haven’t twisted the JVM, or antyhing application server parameter, everything comes out of the box).

To calculate the startup time, I don’t do any fancy rocket science either. I just start the server a few times, check how long it takes and use the best startup time. Also remember that some servers do not load any container at startup, making them very fast to start. Others load everything (making them slower). Again, I have to point out that I’m not deploying an application, so it’s really starting up the server from a fresh install. To calculate the memory footprint, I just use the Windows task manager and check the size of the java.exe process.

Disclaimer bis : Some of these servers were completely unknown for me, so I might not have been completely accurate. Feel free to leave a comment.

Disclaimer Ter : And again, this is not a real benchmark, so don’t use it to sale any product to your customer ;o) I just wanted to give an overview of most application servers and some numbers.

Geronimo

Geronimo is the Apache Java EE 5 application server.

Geronimo 2.x

Geronimo 2.x comes with two flavours : one bundle with Jetty, the other one with Tomcat (the one I’ve picked up).

Version 2.1.4
What do you get ? Java EE 5
Who is behind? Apache
Open source? ASL
Documentation Documentation
Download Zip file
Size of the downloaded file 73.5 Mb
Installation mode Unzip
Size once installed on drive 101 Mb
How to start it Execute %GERONIMO_HOME%\bin\geronimo start
Location of log files %GERONIMO_HOME%\var\logs
Best startup time 17.6 s
Size of the process in RAM at startup 118.8 Mb
Welcome page http://localhost:8080/
Admin console http://localhost:8080/console/portal/Welcome (*)

(*) user : system / pwd : manager

GlassFish

GlassFish is the open source reference implementation of the last Java EE specifications.

GlassFish 2.x

GlassFish v2 is the reference implementation of Java EE 5.

Version 2.1.1-b31g
What do you get ? Java EE 5
Who is behind? Sun
Open source? Dual license CDDL and GPL
Documentation Documentation
Download Jar file
Size of the downloaded file 62.9 Mb
Installation mode First java -Xmx256m -jar filename.jar and then ant -f setup.xml
Size once installed on drive 128 Mb
How to start it Execute %GLASSFISH_HOME%\bin\asadmin start-domain
Location of log files %GLASSFISH_HOME%\domains\domain1\logs
Best startup time 12 s
Size of the process in RAM at startup 96.3 Mb
Welcome page http://localhost:8080/
Admin console http://localhost:4848

GlassFish 3.x

GlassFish v3 is the reference implementation of Java EE 6.

Version 3.0
What do you get ? Java EE 6
Who is behind? Sun
Open source? Dual license CDDL and GPL
Documentation Documentation
Download Zipfile
Size of the downloaded file 73.6 Mb
Installation mode Unzip
Size once installed on drive 90.4 Mb
How to start it Execute %GLASSFISH_HOME%\bin\asadmin start-domain
Location of log files %GLASSFISH_HOME%\domains\domain1\logs
Best startup time 5.6 s
Size of the process in RAM at startup 76.2 Mb
Welcome page http://localhost:8080/
Admin console http://localhost:4848

JBoss

JBoss is the RedHat open source application server.

JBoss 5.x

JBoss 5 is a Java EE 5 application server

Version 5.1.0-GA-jdk6
What do you get ? Java EE 5
Who is behind? JBoss/RedHat
Open source?
Documentation Documentation
Download Zip file
Size of the downloaded file 127 Mb
Installation mode Unzip
Size once installed on drive 151 Mb
How to start it Execute %JBOSS_HOME%\bin\run (*)
Location of log files %JBOSS_HOME%\server\default\log
Best startup time 1m 17 s
Size of the process in RAM at startup 242.7 Mb
Welcome page http://localhost:8080/
JMX console http://localhost:8080/jmx-console/

(*) That’s using the default domain

JBoss 6.x

JBoss is still a work in progress. It will eventually implement Java EE 6.

Version 6.0.0-M1
What do you get ? Java EE 6
Who is behind? JBoss/RedHat
Open source? Dual license CDDL and GPL
Documentation Documentation
Download Zipfile
Size of the downloaded file 154 Mb
Installation mode Unzip
Size once installed on drive 180 Mb
How to start it Execute %JBOSS_HOME%\bin\run
Location of log files %JBOSS_HOME%\server\default\log
Best startup time 59.7 s
Size of the process in RAM at startup 225.2 Mb
Welcome page http://localhost:8080/
JMX console http://localhost:8080/jmx-console/

Jetty

Jetty provides an HTTP server, HTTP client, and a Servlet container.

Jetty 6.x

Version 6.1.22
What do you get ? Servlet 2.5
Who is behind? Intalio
Open source? Yes with Apache License 2.0 (*)
Documentation Jetty Documentation
Download Zip file
Size of the downloaded file 24.3 Mb
Installation mode Unzip the file
Size once installed on drive 69.3 Mb
How to start it Execute %JETTY_HOME%\java -jar start.jar
Location of log files %JETTY_HOME%\logs
Best startup time 7.1 s
Size of the process in RAM at startup 26.8 Mb
Welcome page http://localhost:8080/
Snoop page http://localhost:8080/test

Jetty 7.x

Version 7.0.1
What do you get ? A servlet 3.0 container
Who is behind? Intalio
Open source? Dual licensing
Documentation Jetty Wiki
Download Zip file
Size of the downloaded file 2.2 Mb
Installation mode Unzip the file
Size once installed on drive 2.8 Mb
How to start it Execute %JETTY_HOME%\java -jar start.jar
Location of log files %JETTY_HOME%\logs
Best startup time 1240 ms
Size of the process in RAM at startup 26.9 Mb
Welcome page http://localhost:8080/

JOnAS

JOnAS is an application server part of the OW2 development community.

JOnAS 5.1.1

Version 5.1.1
What do you get ? Java EE 5
Who is behind? OW2
Open source? LGPL
Documentation JOnAS Documentation
Download Zip file
Size of the downloaded file 134 Mb
Installation mode Unzip the file
Size once installed on drive 148 Mb
How to start it Execute %JONAS_HOME%\bin\jonas start
Location of log files %JONAS_HOME%\logs
Best startup time 15.3 s
Size of the process in RAM at startup 73.6 Mb
Welcome page http://localhost:9000/
Admin page http://localhost:9000/jonasAdmin

Resin

Resin provides an HTTP server, HTTP client, and a javax.servlet 2.5 container.

Resin 3.x

Version 3.1.9
What do you get ? Servlet 2.5
Who is behind? Caucho
Open source? Yes with GPL License
Documentation Documentation Index
Download Zip core
Size of the downloaded file 9.9 Mb
Installation mode Unzip the file
Size once installed on drive 26.6 Mb
How to start it Execute %RESIN_HOME%\httpd.exe
Location of log files %RESIN_HOME%\logs
Best startup time 1752 ms
Size of the process in RAM at startup There are 3 processes : httpd (2.8 Mb), a console to start/stop (48Mb), a process (24.3Mb)
Welcome page http://localhost:8080/
Admin console http://localhost:8080/resin-admin/

Resin 4.x

Resim 4.x is still in development. It implements the Java EE 6 Web Profile.

Version 4.0.2
What do you get ? Java EE 6 Web Profile
Who is behind? Caucho
Open source? Yes with GPL License
Documentation Documentation Index
Download Zip core
Size of the downloaded file 16.9 Mb
Installation mode Unzip the file
Size once installed on drive 28.2 Mb
How to start it Execute %RESIN_HOME%\resin.exe console
Location of log files %RESIN_HOME%\logs
Best startup time 1640 ms
Size of the process in RAM at startup 49 Mb
Welcome page http://localhost:8080/
Admin console http://localhost:8080/resin-admin/

Tomcat

Apache Tomcat is an open source software implementation of the Servlet specification. So we can say it’s a web container that servers Servlets and JSPs.

Tomcat 6.x

Version 6.0.20
What do you get ? Servlet 2.5
Who is behind? Apache
Open source? Yes with Apache Software License
Documentation Documentation Index
Download Zip core
Size of the downloaded file 6.1 Mb
Installation mode Unzip the file
Size once installed on drive 9.8 Mb
How to start it Execute %TOMCAT_HOME%\bin\startup.bat
Location of log files %TOMCAT_HOME%\logs
Best startup time 591 ms
Size of the process in RAM at startup 23.3 Mb
Welcome page http://localhost:8080/
Admin console (*) http://localhost:8080/manager/html

(*) To be able to log on to the admin console, you need to change the %TOMCAT_HOME%\conf\tomcat-users.xml configuration files and add a manager role.

Weblogic

Oracle Weblogic server belonged once to BEA and is a Java EE 5 application server.

Weblogic 10.x

Version 11g Rel 1 (10.3.2)
What do you get ? Java EE 5
Who is behind? Oracle
Open source? No, commercial product
Documentation Weblogic Server Documentation
Download Installer
Size of the downloaded file The installer is only 42 Mb. But the total downloaded is 738 Mb
Installation mode Run the installer wizard with the Typical install type
Size once installed on drive 1.2 Gb
How to start it You need to create a domain with the wizard.
Then run %WEBLOGIC_HOME%\user_projects\domains\base_domain\bin\startWebLogic.cmd
JDK bundled 1.6.0_14
Location of log files %WEBLOGIC_HOME%\user_projects\domains\base_domain\servers\AdminServer\logs
Best startup time 9 s
Size of the process in RAM at startup 126.2 Mb
Admin console http://localhost:7001/console

Websphere

Websphere 7.x

Websphere 7 is the Java EE 5 application server of IBM.

Version 7
What do you get ? Java EE 5
Who is behind? IBM
Open source? No, commercial product
Documentation Documentation
Download Zip file
Size of the downloaded file 838 Mb
Installation mode Unzip + Wizard install (with all the defaults)
Size once installed on drive 1.16 Gb
How to start it Execute %WEBSPHERE_HOME%\AppServer\profiles\AppSrv01\bin\startServer.bat server1 -profileName AppSrv01
Location of log files %WEBSPHERE_HOME%\AppServer\profiles\AppSrv01\logs\server1
Best startup time 47.2 s
Size of the process in RAM at startup 133 Mb
Admin console https://localhost:9043/ibm/console

Conclusion

There is not a real conclusion that you can take out of these tests, just some hints and numbers to show you that things are moving. Comparing Websphere with Tomcat is like comparing apples with bananas. Of course Tomcat is way faster and lighter than Websphere, but it doesn’t do the same thing. Also some application servers are minimalist and only come with application containers. On the other hand, other come with integrated portals and so on. So, of course, the startup time is different.

All that to say that the figures of the table below have to be taken with respect of what the application server does (remember that Tomcat and Jetty are just servlet containers). In red the less efficient, in orange the second less efficient, in green the most efficient, in blue the second most efficient.

App server What you get Size on drive Startup time Process size
Geronimo 2.x Java EE 5 101 Mb 17.6 s 118.8 Mb
GlassFish 2.x Java EE 5 128 Mb 12 s 96.3 Mb
GlassFish 3.x Java EE 6 90.4 Mb 5.6 s 76.2 Mb
JBoss 5.x Java EE 5 151 Mb 1m 17 s 242.7 Mb
JBoss 6.x Java EE 6 180 Mb 59.7 s 225.2 Mb
Jetty 6.x Servlet 2.5 69.3 Mb 7.1 s 26.8 Mb
Jetty 7.x Servlet 3.0 2.8 Mb 1240 ms 26.9 Mb
JOnAS 5.x Java EE 5 148 Mb 15.3 s 73.6 Mb
Resin 3.x Servlet 2.5 26.6 Mb 1752 ms 75.1 Mb
Resin 4.x Java EE 6 Web Profile 28.2 Mb 1640 ms 49 Mb
Tomcat 6.x Servlet 2.5 9.8 Mb 591 ms 23.3 Mb
Weblogic 10.x Java EE 5 1.2 Gb 9 s 126.2 Mb
Websphere 7.x Java EE 5 1.16 Gb 47.2 s 133 Mb

Java EE 5

If you only concentrate on the Java EE 5 implementation, you’ll get the sub-table below :

App server Size on drive Startup time Process size
Geronimo 2.x 101 Mb 17.6 s 118.8 Mb
GlassFish 2.x 128 Mb 12 s 96.3 Mb
JBoss 5.x 151 Mb 1m 17 s 242.7 Mb
JOnAS 5.x 148 Mb 15.3 s 73.6 Mb
Weblogic 10.x 1.2 Gb 9 s 126.2 Mb
Websphere 7.x 1.16 Gb 47.2 s 133 Mb

When you read this table there are things that you would have not expected. For example, JBoss is the slowest server to startup and Weblogic is the fastest. JBoss is also the one that has the biggest memory footprint. Websphere has the second less efficient score of all categories, while GlassFish has the second most efficient scores. JOnAS, on the other hand, has the smallest memory footprint.

Again, I haven’t deployed any application, used the administration console extensively, created clusters and did any fancy performance tests. But I wanted to show you that a full Java EE 5 server can start in 9 seconds or can only take 73 Mb or RAM. With Java EE 6 coming and the Web Profile, application servers have to become more modular and carry less weight. GlassFish v3 is a good example as it starts up in only 5.6 seconds and Resin 4 in 1640 ms. Application servers today are not the same that when they were created 10 years ago. Things have changed : Java EE 6 has become lighter, and so are the application servers.

PS : If I have omitted an application server that you (and I) think is important, let me know and I’ll give it a try and add it to the list. If you have any information to report, feel free to leave a comment.

Exit mobile version