Table of Contents
Please read general Migration Guide page first, for common considerations that apply to migration or upgrade between versions of Apache Tomcat.
Migrating from 7.0.x to 8.0.x
This section lists all the known changes between 7.0.x and 8.0.x which may cause backwards compatibility problems when upgrading.
Java 7 required
Apache Tomcat 8.0.x requires Java 7 or later. Apache Tomcat 7.0.x required Java 6.
Apache Tomcat 8 supports the Java Servlet 3.1, JavaServer Pages 2.3, Java Unified Expression Language 3.0 and Java WebSocket 1.0 specifications. The changes between versions of specifications may be found in the Changes appendix in each of specification documents.
Servlet 3.1 API
In JSP pages that use wildcard import syntax the new classes added in
Servlet API may conflict with ones in web applications.
For example, if package
"a" contains class
ReadListener, the following JSP page will cease to compile in
<%@page import="a.*"%> <% ReadListener listener = new ReadListener(); %>
This happens because implicit import of
and explicit import of
a.* will provide conflicting
definitions of class
ReadListener that was added in Servlet
3.1. The solution is to use the explicit import,
Default connector implementation
The default HTTP and AJP connector implementation has switched from the Java blocking IO implementation (BIO) to the Java non-blocking IO implementation (NIO). BIO may still be used but Servlet 3.1 and WebSocket 1.0 features that use non-blocking IO will then use blocking IO instead which may cause unexpected application behavior.
Web application resources
The Aliases, VirtualLoader, VirtualDirContext, JAR resources and external repositories features that all provided a way to add resources to a web application have been replaced with a single framework rather than each being implemented separately (this was becoming increasingly difficult to maintain). The resources documentation provides details on how the new implementation may be used.
When starting Tomcat with the
jpda option to enable remote
debugging, Tomcat 8 listens on
localhost:8000 by default.
Earlier versions listened on
*:8000. If required, this default
can be overridden by setting the
variable in, for example,
Whilst the Tomcat 8 internal API is broadly compatible with Tomcat 7 there have been many changes at the detail level and they are not binary compatible. Developers of custom components that interact with Tomcat's internals should review the JavaDoc for the relevant API.
Of particular note are:
- The Manager, Loader and Resources have moved from Container to Context since Context is the only place they are used.
- The Mapper has moved from the Connector to the Service since the Mapper is identical for all Connectors of a given Service.
- A new Resources implementation that merges Aliases, VirtualLoader, VirtualDirContext, JAR resources and external repositories into a single framework rather than a separate one for each feature.
When upgrading instances of Apache Tomcat from one version of Tomcat 8 to another, particularly when using separate locations for $CATALINA_HOME and $CATALINA_BASE, it is necessary to ensure that any changes in the configuration files such as new attributes and changes to defaults are applied as part of the upgrade. To assist with the identification of these changes, the form below may be used to view the differences between the configuration files in different versions of Tomcat 8.
Tomcat 8.0.x configuration file differences
Select a configuration file, old version and new version from the boxes below and then click "View differences" to see the differences. The differences will be shown in a new tab/window.
You can also use Subversion command similar to the following (all on one line):
svn diff --old=http://svn.apache.org/repos/asf/tomcat/tags/TOMCAT_8_0_0/conf/ --new=http://svn.apache.org/repos/asf/tomcat/tags/TOMCAT_8_0_1/conf/