Oracle announced the release of JDK 22 GA this Tuesday.
“JDK 22 delivers 12 enhancements that are significant enough to warrant their own JDK Enhancement Proposals (JEPs), including seven preview features and one incubator feature. They cover improvements to the Java Language, its APIs, its performance, and the tools included in the JDK.” Continue Reading…
Oracle Java JDK 19 is out! Here are the new features and how to install instructions for Ubuntu users.
First, for Linux users the release now ported to support the RV64GV configuration of RISC-V, a general-purpose 64-bit ISA.
The release also introduced record patterns to deconstruct record values. Record patterns and type patterns can be nested to enable a powerful, declarative, and composable form of data navigation and processing. Though it’s a preview feature so far.
There are also 2 other preview features: a foreign function & memory API can interoperate with code and data outside of the Java runtime; a lightweight virtual threads that dramatically reduce the effort of writing, maintaining, and observing high-throughput concurrent applications; pattern matching for switch expressions and statements.
JDK 19 also introduced an API to express vector computations that reliably compile at runtime to optimal vector instructions, and an API for structured concurrency.
Other changes include:
New system properties for System.out and System.err.
upgrade Unicode support to 14.0
HTTPS channel binding support for Java GSS/Kerberos.
Support for PAC-RET protection on Linux/AArch64
Add a -providerPath option to jarsigner
New options for ktab to provide Non-Default salt
As well, there are removed and deprecated APIs and features. See release note details.
How to Install Java JDK 19 in Ubuntu Linux:
Oracle website provides the 64-bit DEB/RPM packages for Debian, Ubuntu, Fedora based systems. Just go download the package for your system from the link below:
In recent Linux systems, you can simply double-click on the package to install via system Software App. To set the Java home variable and use JDK 19 as default, see this step by step how to tutorial.
This simple tutorial shows how to install the latest Oracle Java (JDK 21 or JDK 23) in Ubuntu Linux via the official binary package.
There used to be unofficial Ubuntu PPA to automate the process of installing Java JDK and setup the environment, however, discontinued. So, here’s the tutorial to manually install the Java package and set as default.
Install JDK 21/23 in Ubuntu:
Press Ctrl+Alt+T on keyboard to open a terminal window and follow the steps below one by one.
NOTE: In all commands below, you need to replace jdk-21 with jdk-23 for installing or uninstall Java JDK 23.
1. Download Java package
Firstly, go to oracle website and select download the .deb package for JDK 21 or 22 depends on which version you want to install:
For choice, you may drag’n’drop the .deb package into terminal, instead of typing ~/Downloads/filename.deb. And, replace number 21 according to which version you downloaded.
For the ARM package (for Raspberry Pi, Apple M1/2, etc), run command to create ‘/usr/lib/jvm’ directory in case it does not exist:
sudo mkdir -p /usr/lib/jvm
Then, extract the tarball to that directory via (For JDK 23, replace the number in command.):
sudo tar -zxf ~/Downloads/jdk-21_linux-aarch64_bin.tar.gz -C /usr/lib/jvm/
3. Set JDK 21/23 as default (for ARM only):
NOTE 1: The .deb package now automatically set Java 21/23 as default! So, you ONLY need to follow the steps below for the ARM package.
NOTE 2: The JDK root folder-name may vary depends on which package you installed. It may be ‘jdk-21’, ‘jdk-21.0.1’, ‘jdk-23’, ‘jdk-23.0.1’, and so forth. Run ls /usr/lib/jvm to tell and replace jdk-21 in commands below accordingly.
a.) Create symbolic links for the executable files:
sudo update-alternatives --install /usr/bin/jar jar /usr/lib/jvm/jdk-21/bin/jar 1
Similarly, add links for other executable files (e.g., jarsigner, jlink, javadoc) as you need.
b.) Next, run the commands below one by one, and type number to select Java JDK 21 as default.
sudo update-alternatives --config java
sudo update-alternatives --config javac
sudo update-alternatives --config jar
When done, verify by running command in terminal:
java -version
javac -version
4. Set JAVA_HOME (for ARM only):
As well, you only need to do this for ARM package. If installed the .deb version, just verify JAVA HOME via the bottom command.
Also, replace ‘jdk-21’ below according to ls /usr/lib/jvm command output.
Option 1.) Set JAVA_HOME for current command console, that will work until you close it:
export JAVA_HOME=/usr/lib/jvm/jdk-21
setenv JAVA_HOME=/usr/lib/jvm/jdk-21
Option 2.) To make it permanent, create and edit config file via command:
sudo gedit /etc/profile.d/jdk.sh
Depends on your desktop environment, you may replace gedit with mousepad for XFCE, xed for Linux Mint, pluma for MATE, kate for KDE Plasma, gnome-text-editor for Ubuntu 24.04+.
Oracle announced the release of Java 17 as the new Long-Term Support (LTS) release.
Java 17 LTS comes with thousands of performance, stability, and security updates, as well as 14 JEPs (JDK Enhancement Proposals). And Oracle will provide 8-year support for the release with security, performance, and bug-fix updates until 2029.
According to the release note, the next LTS will be Java 21 planned for September 2023, which changes the LTS release circle for every three years to two years.
What’s New in Oracle Java 17:
JDK 17 includes new language enhancements, updates to the libraries, support for new Apple computers, removals and deprecations of legacy features, and work to ensure Java code written today will continue working without change in future JDK versions. It also offers a language feature preview and incubating APIs to gather feedback from the Java community.
Updates in the release include:
Sealed classes and interfaces restrict which other classes or interfaces may extend or implement them.
Restore Always-Strict Floating-Point Semantics
New interface types and implementations for Pseudo-Random Number Generators (PRNGs), including jumpable PRNGs and an additional class of splittable PRNG algorithms (LXM).
Implement a Java 2D pipeline for macOS using the Apple Metal API.
New Arm 64-based Apple Silicon computers support.
Deprecate the Applet API for removal
Remove the Remote Method Invocation (RMI) Activation mechanism
Remove the Experimental AOT and JIT Compiler
Deprecate the Security Manager for removal
Strongly encapsulate all internal elements of the JDK, except for critical internal APIs such as sun.misc.Unsafe.
Pattern matching for switch expressions and statements, along with extensions to the language of patterns.
Improves Foreign Function and Memory API and Vector API.
How to Install Oracle Java 17 in Ubuntu:
Thanks to the “Linux Uprising” team ppa, an installer script has been created to automatically downloads and installs Oracle JDK 17 package, and sets Java 17 as the default Java version (setting JAVA_HOME, etc.) on 64-bit PC and arm64 devices, e.g., Rasperry Pi and Microsoft HoloLens 2.
1.) Firstly, open terminal either from system start menu or by pressing Ctrl+Alt+T on keyboard. When it opens, run command to add the PPA:
sudo add-apt-repository ppa:linuxuprising/java
Type user password when it asks (no asterisk feedback) and hit Enter to continue.
2.) Refresh system package cache. The PPA provides packages for Ubuntu 18.04, Ubuntu 20.04, Ubuntu 21.04, Ubuntu 21.10, as well as two old Ubuntu LTS (14.04 and 16.04). And old Ubuntu releases need to manually update system cache by running the command below in terminal:
sudo apt-get update
3.) Finally install the script package via command:
sudo apt-get install oracle-java17-installer
Once the script starts, it brings you to the screen for the license. Press Tab key on keyboard to select OK and hit Enter.
Then answer “Yes” via arrow keys and hit Enter to start downloading Java 17 package from oracle website.
Terminal will indicate the downloading and installing process for you. When everything’s done successfully, use java --version or javac --version command to verify the installation.
Ability to open HTML files in Edge using the Open in Browser action.
Fixed IntelliJ IDEA freezes.
Git: The built-in SSH doesn’t fail when Git protocol version 2 is enabled.
Fixed regressions in Mercurial support.
Docker: the IDE now validates Command line options and reports unknown options.
Docker: volume mounting now works on Windows using Linux containers.
Minor Gradle bug-fixes.
How to Insall the Latest IntelliJ IDEA in Ubuntu:
It’s quite easy to install the latest IDEA packages in Ubuntu since Jetbrains offers official snap (containerised software package) package in snappy store.
Simply open Ubuntu Software, search for and you’ll see IDEA ultimate and community packages available for install.
NOTE for Ubuntu 16.04 users who never installed a snap package, make sure snapd is installed by running command in terminal (Ctrl+Alt+T):
Full Eclipse IDE user experience for building, debugging, running and packaging Rust applications.
Expanded C# editing and debug capabilities, including syntax coloring, autocomplete suggestions, code diagnostics, and code navigation tools.
Java 9, Java 10 and JUnit 5 support.
Dark theme improvements in text colors, background color, popup dialogs, mark occurrences, and more.
How to Install Eclipse 4.8 Photon in Ubuntu:
The community has built the snap package of Eclipse Photon. It’s an universal Linux package format that bundles all its dependencies, and auto-updates itself once a new release is published.
The Eclipse 4.8.0 snap can by easily installed in Ubuntu Software:
Note that there are two versions of Eclipse in Ubuntu Software. Take a look at the version number before installing the package.
You can also install the snap by running command in terminal:
snap install --classic eclipse
In addition:
1. For Ubuntu 16.04 users never installed a snap package, make sure snapd daemon is installed via command:
sudo apt-get install snapd snapd-xdg-open
2. For Java environment, either install the OpenJDK via command:
Jet Brains announced the release of IntelliJ IDEA 2017.3 earlier today. Here’s how to install it in Ubuntu 14.04, Ubuntu 16.04, Ubuntu 17.10, and Ubuntu 18.04.
IntelliJ IDEA 2017.3 is a new massive release that includes loads of new features and dozens of important bugfixes. See the release note for details.
How to Install IntelliJ IDEA 2017.3 in Ubuntu:
There are a few ways to run the latest release of the Java IDE in Ubuntu desktop. And here are 3 of them:
method 1: Download official Linux package (NON-INSTALL), extract and run the executable to launch the IDE:
method 2: Install the Snap package for Ubuntu 16.04 and higher:
Open terminal via Ctrl+Alt+T or by searching ‘terminal’ from app launcher. When it opens, run command: