-
Bug
-
Resolution: Won't Fix
-
Major
-
None
I'm on jdk-tool:1.1 and Jenkins 2.138.2. I've configured JDK10 in Global Tools per the attached screenshot. When running a job that uses it, I get:
Installing JDK jdk-10.0.2-oth-JPR 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 [Pipeline] } [Pipeline] // withEnv [Pipeline] } [Pipeline] // node [Pipeline] End of Pipeline java.io.IOException: Failed to request https://download.oracle.com/otn-pub/java/jdk/10.0.2+13/19aef61b38124481863b1413dce1855f/jdk-10.0.2_linux-x64_bin.tar.gz?AuthParam=1541612216_106847a9a60b4e512bb6e81d31a78d22 exit code=404
I believe these URLs should be:
http://download.oracle.com/otn
instead of:
http://download.oracle.com/otn-pub
I've tried using other installer methods such as Extract .zip/.tar.gz and also the Custom Tool plugin instead, but these lack the authentication-handling needed to download JDK from Oracle.
If the "Install from java.sun.com" method is currently broken, how are people using the official JDK with Jenkins? Doesn't seem to be a public docker image for it. Is everyone using openjdk instead? Or maintaining their own jdk docker images?
brendanh Those URLs come straight from the crawler (You can see them listed here https://updates.jenkins.io/updates/hudson.tools.JDKInstaller.json), so you'd need to update this file so that it produces the right links for JDK 10 (maybe as simple as fixing the initial landing page for JDK 10?). If you want to take that on, I am happy to review your work, but I do not expect to be able to work on this myself anytime soon.
See this comment in
JENKINS-54305for recommended ways to use a specific JDK. "Install from java.sun.com" should be considered deprecated and I would not use it.