With Azul Zulu OpenJDK 15, for this post I did some experiments with Java 15, reusing the Ubuntu 64bit SD card which was also used for my earlier post “Startup Speed of Spring and Quarkus JARs on the Raspberry Pi”.
Do you need to switch from OpenJDK 11 to 15? No, not really, based on these results. But each new version has bug and security fixes, new features, and generic improvements!
For my book “Getting Started with Java on Raspberry Pi”, an example was described to store sensors and measurements in an H2-database through REST APIs with a Spring application on the Raspberry Pi.
The application takes some time to start on a Raspberry Pi, and Adam Bien who does the airhacks.fm podcast, asked me if I could compare this to a similar Quarkus application, which resulted in some nice results.
Now that Java 15 has been released, let’s take a look at what’s new!
Here on foojay, the fixes that went into the release are listed, giving you a unique and readable changelog in helpful categories, with the invitation for you to vote on those that are most relevant to you.
Everyone who programs in Java, or any of the other languages built on top of the Java Virtual Machine (Scala, Closure, Kotlin, Groovy, Nashorn, Jython, JRuby, et al.) is familiar with the term “bytecode.”
But how many of us understand what JDK bytecode actually is?
A couple of weeks ago, JavaFX version 15 was released.
These are some of the highlights we’ve selected for you to understand its scope.
– JavaFX now has 3D support for the newer Intel graphics drivers on Linux,
– Support for e-paper displays on i.MX6 devices was added,
– FX scripting support was enhanced.
The HotSpot JVM has a lot of options available. Maybe too many. Sometimes we are looking for a specific option or the “magic” one that can give a serious boost in an application.
I have summed up here, in my humble opinion, some of the most useful JVM options in the context of heap sizing.
The site you’re on, foojay.io, has had a bit of a facelift over the past week.
Now you can see directly on the homepage all the key pieces that make up foojay, a place for friends of OpenJDK.
Clearer now is its focus on the integrated services provided by Marc Hoffmann’s Java Version Almanac and Chris Newland’s JVM Options Explorer, supported by the OpenJDK Update Release Details, together with Foojay Today and the start of Foojay Pedia.
Let’s continue from part 1 of this series, by looking at JEP 330, Launch Single-File Source-Code Programs, which is one of the new features introduced in the OpenJDK 11 release. This feature allows you to execute a Java source code file directly using the java interpreter.
The source code is compiled in memory and then executed by the interpreter, without producing a .class file on disk.
However, this feature is limited to code that resides in a single source file. You cannot add additional source files to be compiled in the same run.
The brilliance of the Java Virtual Machine is that it is itself an operating system.
In other words, if you use the JVM as your base platform, you don’t have to worry about numerous “if” statements related to the specifics of hardware and operating systems.
The JVM takes care of all of that for you. Whatever you write, it’s going to run perfectly on any operating system and hardware that supports the Java Virtual Machine.
Instead of starting up the JVM, loading a class and executing the code, you can run single Java source files.
This feature is particularly useful for someone new to the language who wants to try out simple programs, you get a great beginner’s learning toolset.
Professionals can also make use of these tools to explore new language changes or to try out an unknown API.
Today we’d like to introduce a new community manager for all things Raspberry Pi on foojay: Frank Delporte!
He’s really curious about what’s already been created with Java on the Raspberry Pi and what we can all learn together from these experiences.
You can contact him with a direct message on Twitter to discuss further and share articles for publication on foojay: https://twitter.com/frankdelporte.