Help with oraclejdk10 build on Linux

build-env

#1

It seems oraclejdk10 support is having a problem. I received the following output with the oraclejdk10 build of my project, but the other builds (oraclejdk8-9 and openjdk8-10) all work fine.

Network availability confirmed.
Setting APT mirror in /etc/apt/sources.list: http://archive.ubuntu.com/ubuntu/
$ export JAVA_HOME=${TRAVIS_HOME}/oraclejdk10
$ bash install-jdk.sh -F 10 -L BCL --target $JAVA_HOME --workspace ${TRAVIS_HOME}/.cache/install-jdk
install-jdk.sh 2018-10-16
Variables:
  feature = 10
  license = BCL
       os = linux-x64
      url = http://download.oracle.com/otn-pub/java/jdk/10.0.2+13/19aef61b38124481863b1413dce1855f/jdk-10.0.2_linux-x64_bin.tar.gz
   status = 302
  archive = /home/travis/.cache/install-jdk/jdk-10.0.2_linux-x64_bin.tar.gz
Downloading JDK from http://download.oracle.com/otn-pub/java/jdk/10.0.2+13/19aef61b38124481863b1413dce1855f/jdk-10.0.2_linux-x64_bin.tar.gz...
The command "bash install-jdk.sh -F 10 -L BCL --target $JAVA_HOME --workspace ${TRAVIS_HOME}/.cache/install-jdk" failed and exited with 8 during .

#2

@sormuras Seems that Oracle is changing the download URLs. Could you tell us how you populate them in install-jdk.sh?


#3

My pattern here is as follows:


#4

The URL used within the script for JDK 10.0.2 seems to be okay – but the problem persists. Maybe Oracle revoked the Cookie support that allowed “headless” downloading of the archive?


#5

Related issue: https://github.com/sormuras/bach/issues/37


#6

The URL doesn’t work for me. I get a 404 if I try to manually download oraclejdk10.


#7

You’re right. Looks like the download link on Oracle’s site is broken…


#8

Looks like Oracle completely disabled the JDK 10 downloads.

Seems like short circuiting the jobs using Oracle JDK 10 to just drop and suggest OpenJDK 10 (with appropriate messages).


#10

The change above is now live.


#11

Here is the changelog entry: https://changelog.travis-ci.com/stop-a-job-early-if-a-deprecated-jdk-is-configured-76612