The Java community has demonstrated time and time again its ability to evolve, improve, and adapt to meet the needs of its developers and users. Even after 25 years of language and framework choices, Java has consistently ranked in the top languages in use today due to its strong track record and capabilities in enterprise use cases. Red Hat has long been a strong leader in Java and open source software development and remains committed to being at the forefront of Java as it continues to evolve.
Today, Red Hat and the GraalVM community jointly established a new downstream distribution of GraalVM, called Mandrel. This distribution will power the Red Hat build of Quarkus, a recently announced addition to Red Hat Runtimes. This article explains what Mandrel is and why it is necessary.
Java going forward
For some time now, Red Hat has been looking at the future of Java and how its customers and their developers could continue to use their years of Java experience in this new world of containers, microservices, and Kubernetes. That Java experience applies to more than the language—it also includes many libraries and frameworks that have become ingrained in the muscle memory of developers, for example: Hibernate, CDI, RESTEasy, MicroProfile, or reactive frameworks such as Eclipse Vert.x and many others.
The Quarkus project was launched in 2019 and provided that evolutionary step needed for Java developers in this new world of Kubernetes and serverless. In essence, Quarkus changes the rules of the Java game. It optimizes both Java applications and the frameworks that underpin them to better match the constrained environments in which they are deployed and reverses the architectural and design choices made in Java’s early days. Quarkus-native applications bring a much smaller memory footprint at the expense of throughput, which is now handled through scaling and elasticity—the same way you find in Kubernetes. It also brings faster startup speeds at the expense of dynamic runtime behavior, which is now unnecessary overhead in immutable deployment architectures—again, like you find in Kubernetes.
Quarkus and GraalVM
GraalVM is an ecosystem and shared runtime offering performance advantages for a variety of languages, including Java. Its ability to do ahead of time compilation to create extremely optimized Java applications has made it particularly well suited for running Java in even smaller footprints than you can get with traditional JVM deployments. With the introduction of the GraalVM project a few years ago, it made a lot of sense to design Quarkus, and the many frameworks it provides, to make it possible to use with this tool. This decision provides further optimization for Quarkus applications and helps them work together seamlessly and easily, without sacrificing the rich APIs developers know and love. GraalVM has become an important part of the Quarkus story, and Red Hat is committed to its success. Red Hat sits on the GraalVM Project Advisory Board and regularly contributes features and fixes for the GraalVM community, such as improved debuggability of native images, AArch64 native image support, and continued work on supporting Java Flight Recorder (JFR).
Red Hat recently announced its support of Quarkus for production use by our customers. By using the Red Hat build of Quarkus, our customers now have a fully supported and highly-optimized Java solution for their Kubernetes and serverless applications. Developers can also use GraalVM to compile their Quarkus apps down to native binaries, further optimizing for cloud and Kubernetes. This feature is currently in Technical Preview as we work with the GraalVM community so we can support Red Hat customers when using it with Quarkus—which brings us to Mandrel.
Mandrel
Red Hat’s dedication to open source communities underpins its enterprise-grade support model. We believe strongly that open source innovation is critical to the success not only of Red Hat but also the communities it serves. GraalVM is a large project with many moving parts, with contributions every day from Red Hat, Oracle, and many other GraalVM community members.
We have found that the best way to support our customers while remaining true to our open source commitment is to establish downstream open source distributions built in concert with their upstream counterparts. You see this with downstream distributions of Linux with Fedora and CentOS, Kubernetes with OKD, and now with Mandrel as a downstream of GraalVM. These communities work hand-in-hand to advance open source technology in a way that makes sense for both. This also enables Red Hat to continue to innovate in the open, even in its productization process, with an “upstream-first” mentality, preferring not to deviate from upstream.
For Quarkus, the important piece of GraalVM is its native-image feature that produces native executables, which is a key feature to make Java competitive in cloud-native workloads. Mandrel allows us to have GraalVM bundled on top of OpenJDK 11 in Red Hat Enterprise Linux and other OpenJDK 11 distributions. On the GraalVM side, this allows features such as the in-progress Java Flight Recorder to be supported in Mandrel sooner than GraalVM if release timing requires it. Thus, Mandrel can best be described as a distribution of a regular OpenJDK with a specially packaged GraalVM native image.
The difference for the user is minimal, but for maintainability the upstream alignment with both OpenJDK 11 and GraalVM is critical. It means that Red Hat can offer better support to customers since we have skilled engineers working within the OpenJDK and GraalVM community.
With Mandrel, both Red Hat customers and the GraalVM community benefit from truly open development, and Red Hat can support its customers with tried-and-true mechanisms while at the same time giving back to the upstream communities it relies on for continuing to advance the state of the art in open source computing.
Last updated: February 11, 2024