CheerpJ 2.2 released

Author(s):
CheerpJ Logo - Java to WebAssembly Compiler

Today we release CheerpJ 2.2, the latest major update to our solution to compile and run Java client applications on modern browsers side thanks to JavaScript and WebAssembly.

About CheerpJ

CheerpJ is a solution to compile ahead of time and execute Java bytecode on the browser in WebAssembly and JavaScript. It comes with a full Java runtime environment, and with Java-JavaScript bidirectional interoperability.

CheerpJ provides several browser-based system functions, including virtualized file systems, I/O, networking and audio. It is a mature technology used by many large organisations worldwide, including Fortune 100 companies and the public sector.

Since release 2.1 (release notes here.), there have been improvements on the generation of stubs for native methods and on how the exceptions are handled, along with a speed-up of our implementation of the native Java reflection calls.

What’s new

Audio

CheerpJ 2.2 resolves a number of audio problems, manifested primarily as audio glitches, with a more solid approach to audio reproduction for which the result can be seen in a video here.

AWT controls

In CheerpJ 2.2, several AWT controls have been reimplemented with a focus on usability and cross-browser compatibility. These include a shiny new scrollbar and text formatting in various text components, while other AWT controls had their functionalities revisited to better reflect the original Java implementation.

Other improvements

Other important features introduced in CheerpJ 2.2 are the support for custom HTTP implementations, a more robust reflection mechanism (native Java reflection is fully supported by CheerpJ), and a fix on how private methods are handled, which are now resolved correctly instead of being added to the class vtable.

The full Change log for version 2.2 of CheerpJ is available here.

Getting started

CheerpJ 2.2 is available for Windows, macOS and Linux.

How to upgrade to CheerpJ 2.2

To try out or update to CheerpJ 2.2, simply download the compiler here , and rebuild your project with the new compiler. If using the CheerpJ cloud runtime, make sure to change your CheerpJ runtime header to

<script src=”https://cjrtnc.leaningtech.com/2.2/loader.js"></script>

The old 2.1 version will keep working, but the only way to gain the benefits of this new release is to change the runtime endpoint and regenerate the jar.js files.

Please notice that using the new runtime with a jar.js generated with the 2.1 compiler might lead to unexpected behaviours.

Download and Try CheerpJ

If you have never tried our compiler before it’s really easy!

Just only have to use our compiler that you can find here and update your HTML page hosting the applet or create a simple HTML for it.

You can follow this link to our wiki and follow the Getting Started for detailed instructions.

Documentation

You can find the Documentation for CheerpJ, together with tutorials and examples, on the CheerpJ Documentation page.

Get in touch!

To report any issues, please use our issue tracker. For any question or comment, you can find us on the CheerpJ Gitter channel.

Thank you!

Leaning Technologies

Latest Blogs