Comparing Apache Tomcat and TomEE

We downloaded Tomcat 7.0.27 and TomEE 1.0.0 and did a quick comparison. Here are the differences we found. The distributions being compared are apache-tomcat-7.0.27.tar.gz and apache-tomee-1.0.0-webprofile.tar.gz.

1. Tomcat is 7,467 KB. TomEE is 27,702 KB.

2. TomEE catalina.bat/catalina.sh has added the OpenEJB javaagent.

3. TomEE server.xml has the extra listener org.apache.tomee.catalina.ServerListener.

4. Tomcat has a lot more MIME mappings. We are not sure why. Could this simply have been overlooked?

5. TomEE has removed

lib/annotations-api.jar
lib/el-api.jar
webapp/examples/

6. TomEE has added

bin/service*
bin/tomee.*
conf/system.properties
conf/tomee.xml
webapp/tomee/

7. TomEE has added the following libraries. We suggest you review these new libaries to make sure it doesn’t create conflicts with your existing application.

endorsed/annotation-api.jar
endorsed/jaxb-*.jar
lib/bval-*.jar
lib/commons-*.jar
lib/geronimo-*.jar
lib/gson-2.1.jar
lib/howl-1.0.1-1.jar
lib/hsqldb-2.2.4.jar
lib/javaee-api-6.0-3-tomcat.jar
lib/javassist-3.15.0-GA.jar
lib/jaxb-impl-2.2.5.jar
lib/kahadb-5.5.1.jar
lib/mbean-annotation-api-4.0.0.jar
lib/myfaces-*.jar
lib/openejb-*.jar
lib/openjpa-asm-shaded-2.2.0.jar
lib/openwebbeans-*.jar
lib/quartz-2.1.3.jar
lib/scannotation-1.0.2.jar
lib/serp-1.13.1.jar
lib/slf4j-*.jar
lib/swizzle-stream-1.6.1.jar
lib/tomee-*.jar
lib/wsdl4j-1.6.2.jar
lib/xbean-*.jar

Here’s the screenshot of the differences using Araxis Merge.

Comparing Apache Tomcat and TomEE


Apache 2 Performance Tuning

Here’s a list of performance tips taken from the official Apache Performance Tuning documentation. This is meant to serve as a quick cheat sheet. For the details, the trade-offs, the why and when to use these optimizations, please read the complete documentation. All these are for tuning your Apache server for every last ounce of performance, and a few are not applicable to many real world Apache installations.

  • Configure MaxClients to prevent swapping. Use top to determine the size of the average Apache process, and divide it by the total available memory. Make sure to leave room for other processes.
  • Use HostnameLookups off.
  • Use IP addresses instead of Allow from domain or Deny from domain.
  • Set FollowSymLinks. Do not set SymLinksIfOwnerMatch.
  • Use AllowOverride None.
  • Do not use wildcards in DirectoryIndex.
  • Creating a type-map file provides better performance than using MultiViews.
  • Remove unused modules. Minimum modules are mod_mime, mod_dir, and mod_log_config.
  • Compile the appropriate MPM.
  • Use –enable-nonportable-atomics during compilation.
  • Set ExtendedStatus off.
  • Disable dynamically loaded modules during compilcation using -DDYNAMIC_MODULE_LIMIT=0.

It’s now unnecessary to configure the MinSpareServers, MaxSpareServers and StartServers settings.