Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am looking at running a java application server on my debian linux webserver, and am looking for a breakdown of the advantages that using either app server would provide me with (or disadvantages). I am using apache 2 as my webserver and have no problem using a non-free appserver if it will provide a better environment in which to work. This will be used for a reasonably simple set of applications.

share|improve this question
up vote 5 down vote accepted

Glassfish is an application server as it handles EJB requests (EJB Container) while Tomcat is a Web Container - it can't handle EJB components. So, what are the components of the application you plan to run. If your application uses Servlets and JSPs, then GlassFish is an overkill. If you have EJBs then you can't use Tomcat anyway. So, I think it starts with your requirements first.

share|improve this answer

Don't forget to consider Jetty. I like very much:

  • its ease of configuration and deployment (just unzip it and optionally edit one config file)
  • the fact that it's easily embeddable in other applications (with a single jar)
  • its support for continuations a lot before the Servlet 3 spec is ready

Check this comparison out, it's done by a Jetty dev, but it's very fair.

Some other comparisons:

share|improve this answer

Tomcat is a decent enough web server for the smaller scale applications. Glassfish, JBoss, Websphere, etc. are heavy weight application servers that support the EJB standard and many more advanced features out of the box. If you want to use Enterprise Javabeans in your application then Glassfish or similar application servers are the way to go; if you only want to develop using servlets & JSPs or possibly a POJO based framework like Spring, Tomcat may be more than enough.

share|improve this answer
What is an "heavy weight" application server? – Pascal Thivent Jul 26 '10 at 7:01

GlassFish is a collection of Java EE containers, one of which is a Web container, Tomcat is just a Web container. so it's really hard to compare with them. In fact GlassFish has some feature which tomcat didn't supported. like: Modular architecture based on OSGi, Image Packaging System

You may check out here Tomcat vs GlassFish comparison article

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.