BT

Facilitating the Spread of Knowledge and Innovation in Professional Software Development

Write for InfoQ

Topics

Choose your language

InfoQ Homepage News Apache Tomcat 11.0 Delivers Support for Virtual Threads and Jakarta EE 11

Apache Tomcat 11.0 Delivers Support for Virtual Threads and Jakarta EE 11

The release of Apache Tomcat 11 marks a significant evolution in the server's development, introducing features and improvements that align it with modern web application standards, particularly supporting the upcoming GA release of Jakarta EE 11. This release is part of a broader trend of transitioning from the legacy Java EE ecosystem to the contemporary Jakarta EE framework, which emphasizes modularity and a more streamlined development experience.

Apache Tomcat 11 brings several notable advancements, and one of the most significant is the support for virtual threads, introduced as part of Java's Project Loom and delivered in JDK 21. Virtual threads are a lightweight concurrency model that simplifies thread management in Java applications, offering a much more scalable solution than traditional threading models.

For developers working with WebSockets, Tomcat 11 offers improved performance and scalability. The WebSocket API, now upgraded to Jakarta WebSocket 2.2, handles real-time, bidirectional communication between clients and servers more efficiently. These changes are especially valuable for applications requiring streaming data or live updates, such as chat applications or collaborative tools. WebSocket improvements are complemented by Tomcat's handling of HTTP/2 and asynchronous processing, ensuring more responsive and scalable web applications.

Tomcat 11 also supports Jakarta Servlet 6.1. This upgrade brings improvements in how web applications handle HTTP requests and also refines asynchronous request processing, providing better performance for long-running tasks. This makes Tomcat 11 more efficient for modern web applications.

Security remains a core focus in this latest release. Tomcat 11 introduces several enhancements in this area, starting with better default configurations for TLS/SSL, making it easier for administrators to establish secure HTTPS connections out of the box.

Tomcat 11 also embraces modern development practices by requiring Java SE 17 as the minimum supported version. This ensures that Tomcat benefits from the latest Java language features and performance improvements, including enhanced memory management, records, and more efficient switch expressions.

One of the more challenging aspects of migrating to Tomcat 11 is the requirement to refactor applications to accommodate the switch from the javax.* to the jakarta.* namespaces. This is a fundamental change for any developer moving from earlier versions of Tomcat, particularly those using Java EE. While Tomcat 11 offers the migration tools to support this transition, it requires careful testing to ensure that applications continue to function correctly with the new namespace.

The Tomcat project started at Sun Microsystems as the reference implementation of the Java Servlet and Java Server Pages Specifications. In 1999, the Tomcat code base was donated by Sun Microsystems to the Apache Software Foundation with the first commit of Tomcat code to an ASF repository occurring 25 years ago. Tomcat 11.0 marks the ninth major release as an ASF project.

About the Author

Rate this Article

Adoption
Style

BT