about.intro.adoc Maven / Gradle / Ivy
///////////////////////////////////////////////////////////////////////////////
Copyright (c) 2023, 2024 Oracle and/or its affiliates.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
///////////////////////////////////////////////////////////////////////////////
= Introducing Helidon 4
:description: Helidon
:keywords: helidon, java, microservices, Helidon Níma, Project Níma
:rootdir: {docdir}/..
include::{rootdir}/includes/attributes.adoc[]
== What's New in This Release
* Introduction of the new Helidon WebServer (Project Níma): a virtual threads-based web server implementation based on https://openjdk.org/jeps/444[JDK Project Loom] virtual threads.
* Removed Helidon's Reactive WebServer and WebClient that were based on Netty. Our new implementations are based on virtual threads that have a blocking style API (Project Níma). Learn more: <>
* Converted other _reactive_ API modules to _blocking_ style APIs. The `io.helidon.common.reactive` APIs will stay as general purpose reactive utilities and operators. Learn more: <>
* Upgraded MicroProfile support to MicroProfile 6 and Jakarta 10 Core Profile running on the Helidon WebServer. Learn more: <>
* Java 21 is required to use Helidon 4.
== Helidon 4 WebServer
Before Helidon 4, the Helidon WebServer was built on Netty and had a reactive API. In Helidon 4 we have replaced this with a new server implementation (Project Níma) that is written from the ground up to take full advantage of Java 21's virtual threads. With virtual threads, threads are no longer a scarce resource to be carefully pooled and managed. Instead they are an abundant resource that can be created as needed to handle nearly unlimited concurrent requests.
Because each request runs in its own dedicated thread, it is free to perform blocking operations -- like calling a database, or another service. And it can do so in a simple synchronous way with no fear of blocking a platform thread and starving other requests. You no longer need to resort to complicated asynchronous code to implement a low-overhead, highly concurrent service.
== Helidon SE
Helidon SE is Helidon's foundational set of APIs. The big change in Helidon 4 is that the use of virtual threads have enabled these APIs to change from asynchronous to blocking. This results in much simpler code that is easier to write, maintain, debug and understand. Existing Helidon 3 SE code will require modification to run on these new APIs, but the effort is well worth the improved performance and simplicity of the resulting code.
To give a very simple example of the differences between Helidon 3 SE and Helidon 4 SE, let's take a look at extracting a JSON body from an HTTP request and doing something with it:
.Helidon 3
[source,java]
----
include::{sourcedir}/about/IntroSnippets.java[tag=snippet_1, indent=0]
----
.Helidon 4
[source,java]
----
include::{sourcedir}/about/IntroSnippets.java[tag=snippet_2, indent=0]
----
== Helidon MP
Helidon MP is Helidon's MicroProfile implementation and in Helidon 4 it supports MicroProfile 6 and the Jakarta EE 10 Core Profile. Your Helidon 3 MicroProfile application should migrate to Helidon 4 fairly easily (the most significant changes are in MicroProfile Metrics 5.0), and since Helidon's MicroProfile server is based on the new Helidon WebServer (Project Níma), you get all the benefits of running on virtual threads.
© 2015 - 2025 Weber Informatics LLC | Privacy Policy