
上QQ阅读APP看书,第一时间看更新
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 are ready for the next step. In the real world, we must have a build tool to help developers to compile, package, and test the Java applications.
Let's install Maven in the next section.