Copyright - Added an inceptionYear element to the POM file. Updated copyright year in the NOTICE to start with 2020.

Initial commits in this repository and the tag for version 0.0.1 were on January 13th 2020.

Though there was a discussion on the dev@ mailing list that mentioned it earlier
("Proposed plan for Tomcat 10", December 16th 2019)
https://lists.apache.org/thread/8yjg6t383jzdz7k1d1zwzgtvwlt8xjd7

JSTL JARs in Tomcat 10.0 were converted with this tool on January 13th 2020.
https://lists.apache.org/thread/g9zfp511of0hjknm6s9qon40gjdht6w8
https://lists.apache.org/thread/m27zpp3xsz39mzqky21fyxcs6cbr12zy
https://github.com/apache/tomcat/commit/f796b98813d4b12f825276a9a353bf498c64d526

The commit f796b98 above apparently was first authored on December 16th 2019 (according to its "Date" header),
but amended and committed on January 13th 2020.
2 files changed
tree: 80a6d2a927817ff2db7bccfa9140aed465184960
  1. .mvn/
  2. src/
  3. .gitignore
  4. .travis.yml
  5. CHANGES.md
  6. LICENSE.txt
  7. mvnw
  8. mvnw.cmd
  9. NOTICE.txt
  10. pom.xml
  11. README.md
README.md

Apache Tomcat migration tool for Jakarta EE

Build Status Coverage Status License

Overview

The purpose of the tool is to take a web application written for Java EE 8 that runs on Apache Tomcat 9 and convert it automatically so it runs on Apache Tomcat 10 which implements Jakarta EE 9.

The tool can be used from the command line or as an Ant task.

Usage

Download

Download a source or binary distribution from https://tomcat.apache.org/download-migration.cgi

Build

Build the migration tool from source with:

./mvnw verify

To run the migration tool locally, you are most likely to want:

target/jakartaee-migration-*-shaded.jar

Migrate

Migrate your Servlet application with:

java -jar jakartaee-migration-*-shaded.jar <source> <destination>

The source should be a path to a compressed archive, a folder or an individual file. The destination will be created at the specified path as a resource of the same type as the source.

INFO This tool will remove cryptographic signatures from JAR files contained in the source, as the changed resources would not match them anymore.

A warning will be logged for each JAR file where the signature has been removed.

This tool is also available on Debian and Ubuntu systems by installing the tomcat-jakartaee-migration package and invoking the javax2jakarta command.

Ant task

The migration tool is available as an Ant task, here is an example:

<taskdef name="javax2jakarta" classname="org.apache.tomcat.jakartaee.MigrationTask" classpath="jakartaee-migration-*-shaded.jar"/>

<javax2jakarta src="webapp.war" dest="webapp.migrated.war" profile="tomcat"/>

Differences between Java EE 8 and Jakarta EE 9

The difference between Java EE 8 and Jakarta EE 9 is that all the Java EE 8 packages in the javax.* namespace have moved to the jakarta.* namespace. Some sub-packages have also been renamed. This migration tool performs all the necessary changes to migrate an application from Java EE 8 to Jakarta EE 9 by renaming each Java EE 8 package to its Jakarta EE 9 replacement. This includes package references in classes, String constants, configuration files, JSPs, TLDs etc.

Note: Not all javax.* packages are part of Java EE. Only those defined by Java EE have moved to the jakarta.* namespace.

Note: It is not necessary to migrate any references to XML schemas. The schemas don't directly reference javax packages and Jakarta EE 9 will continue to support the use of schemas from Java EE 8 and earlier.

Legal

This tool modifies web application content as described in the previous section. This may include modification of third-party provided content. It is strongly recommended that you confirm that the license(s) associated with any third-party content permit such modifications, especially if you intend to distribute the result.