CheerpJ WebAssembly-based JVM Version 4.1 Is Here
Written by Nikos Vaggalis   
Thursday, 12 June 2025

If you thought that legacy apps are not used anymore in this day and age, think again. With pre-4 version CheerpJ you could run legacy Java apps on browsers. With version 4+ you can run modern apps too.

The newest version of the WebAssembly based JVM, CheerpJ, v 4.1, is out with the biggest change being that it now has  preliminary support for Java 17. It comes just one month after release 4.0, which had brought support for Java 11.

The deal is that the pre-4 versions were using Java 8 as the baseline, but as the Java ecosystem modernizes it was time for CheerpJ to upgrade too, by moving on to support modern LTS releases.

The way it juggles different JDKs is that while CheerpJ for Java 11 and 17 is distributed with both runtimes, thanks to its on-demand package loading architecture, only the relevant runtime is loaded dynamically at runtime.

As a refresher, CheerpJ's main characteristics are :

  • No server side component is required. All the code is run on the client via WebAssembly and JavaScript.
  • Works from unmodified JAR files (no need for source code), no need for any compilation or preprocessing step. Works with obfuscated bytecode, independently of the obfuscator being used.
  • Supports graphical applications, both AWT- and Swing-based ones are supported, including third-party Look&Feels. Multiple applications, each with multiple windows, can run at the same time.
  • Full support for reflection and classloaders, including custom ones designed to support plugins or encrypted JARs.

The fact that it can run unmodified JAR files has been showcased by creating a side project named Browsercraft, a web-based Java version of Minecraft which is not based on decompilation or reverse engineering. Rather the original client.jar and its LWJGL dependency, available from Maven, runs unmodified on the end-user browser.

The new 4.0 and 4.1 versions combined introduce:

  • Support for Java 11
  • Preview of Java 17 support
  • Support for web-native WebAssembly components via the JNI
  • Significant performance improvements
  • Support for SSL and Audio in Java 11
  • Improved networking stack
  • Improvements to mobile usability, for both Swing and AWT

CheerpJ is also built with interoperation in mind as the Java app that runs inside the browser can call native Java libraries which are loaded and executed dynamically and are wrapped as WebAssembly modules accessible through JNI WebAssembly.

Ultimately, CheerpJ aims to become THE enterprise grade distribution of OpenJDK in WebAssembly that allows most UI-based Java Desktop applications to run in the browser.

 

More Information

 CheerpJ 4.1: Java in the browser, now supporting Java 17 (preview)

Related Articles

CheerpJ 3.0 - Run Java Apps Inside The Browser    

 

To be informed about new articles on I Programmer, sign up for our weekly newsletter, subscribe to the RSS feed and follow us on Twitter, Facebook or Linkedin.

Banner


Jakarta EE 11 Modernises Test Kits
26/06/2025

The Eclipse Foundation has announced the general availability of the Jakarta EE 11 Platform. This release has modernised Test Compatibility Kits (TCKs), and introduces the Jakarta Data speci [ ... ]



pg_disatch - Run SQL Queries Asynchronously On PostgreSQL
24/06/2025

pg_disatch is meant to be a TLE-compliant alternative to pg_later but built on top of pg_cron. What makes it different?


More News

pico book

 

Comments




or email your comment to: comments@i-programmer.info

Last Updated ( Thursday, 12 June 2025 )