You have two options when installing java. You can use Oracle Java JDK or you can use OpenJDK. For the Oracle version you will need to read the license agreement to see if there is a fee associated with installing it. The OpenJDK which is contributed to by Oracle is open source and free. OpenJDK is the the version of java that is installed on most free Linux distributions by default.
From installation guide...
ALM requires Java Development Kit (JDK) or Java Runtime Environment (JRE) to be installed
prior to installing ALM (only x64 is supported).
Oracle Java JDK or JRE
Download and install JDK or JRE from the following URL:
1. Download from the following URL: https://adoptopenjdk.net/releases.html.
2. Unzip the OpenJDK file to a folder.
3. Open the System Properties dialog box. In the Advanced tab, click Environment Variables.
4. Under System Variables, edit the Path and add the OpenJDK bin path (for example:
5. To verify that Java was installed correctly, run java -version in the command prompt.