Installing OpenJDK

OpenJDK is a stable, free, and open source Java development kit. This package will be required for everything related to code compilation and runtime environments. 

Also, it is possible to use an Oracle JDK, but you should pay attention to the License and Agreements

To install OpenJDK, we will open a terminal and run the following command:

sudo apt-get install openjdk-8-jdk -y
We can find more information on how to install Java 8 JDK in the installation section (http://openjdk.java.net/install/) of the OpenJDK page.

Check the installation using the following command:

java -version

You should see the OpenJDK version and its relevant details displayed as follows:

Now that we have installed the Java development kit, we ...

Get Spring 5.0 By Example now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.