Difference Between Glassfish and Tomcat

Main Difference

Tomcat is merely an HTTP server and Java servlet container. Glassfish is full-blown Java EE application servers, including an EJB container and all the other features of that stack. Tomcat has a lighter memory footprint (~60-70 MB), while those Java EE servers weigh in at hundreds of megs. Tomcat is very popular for simple web applications, or applications using frameworks such as Spring that do not require a full Java EE server. Comparatively the administration of Tomcat server is more easier than administration of Glassfish as there are fewer moving parts in Tomcat.

What is Glassfish?

Glassfish is full-blown Java EE application servers, including an EJB container and all the other features of that stack. It comes from the Oracle and thus each and every new spec will be tested and implemented with Glassfish first.

What is Tomcat?

Tomcat is merely an HTTP server and Java servlet container. It is run by Apache community. Tomcat is open source and free. It supports all Java EE technologies. It is not supported by any commercial support but only supported by community.

Key Differences

  1. Tomcat is merely an HTTP server and Java servlet container. Glassfish is full-blown Java EE application servers, including an EJB container and all the other features of that stack.
  2. Tomcat has a lighter memory footprint as compare to Glassfish.
  3. Tomcat has footprint memory of 60-70 MB, while those Java EE servers weigh in at hundreds of Megs.
  4. Tomcat is very popular for simple web applications as compare to Glassfish.
  5. Comparatively the administration of Tomcat server is more easier than administration of Glassfish as there are fewer moving parts in Tomcat.
  6. Both of the Tomcat and Glassfish are open source and free but have different licenses.
  7. Glassfish is dual licensed while Tomcat has single license.
  8. Tomcat uses the Apache License while Glassfish has been licensed under CDDL and GPL.
Harlon Moss

Harlon currently works as a quality moderator and content writer for Difference Wiki. He graduated from the University of California in 2010 with a degree in Computer Science. Follow him on Twitter @HarlonMoss

View all posts by Harlon Moss