Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

testJavaVersion() doesn't stop execution instantly after java -version return the non-zero status #4082

Closed
sophia-guo opened this issue Oct 24, 2022 · 1 comment · Fixed by #4177
Assignees

Comments

@sophia-guo
Copy link
Contributor

java -version of testJavaVersion() in get.sh didn't stop execution instantly when return the non-zero status. Example is jdk has been pointed to wrong one ( for example , pointing a linux jdk on a mac platform), which makes the error message confusing.

At the begin part of get.sh flag set -e has been set to stop execution instantly when non-zero status returns, which seems doesn't work for all situations?

05:13:09  _ENCODE_FILE_NEW=UNTAGGED curl -OLJSks --user ****:**** https://ci.adoptopenjdk.net/job/build-scripts/job/openjdk19-pipeline/237/artifact/target/linux/aarch64/temurin/OpenJDK19U-jdk_aarch64_linux_hotspot_19.0.1_10.tar.gz
05:14:25  Uncompressing file: OpenJDK19U-jdk_aarch64_linux_hotspot_19.0.1_10.tar.gz ...
05:14:25  Run /Users/jenkins/workspace/Grinder/openjdkbinary/j2sdk-image/bin/java -version
05:14:25  =JAVA VERSION OUTPUT BEGIN=
05:14:25  ./get.sh: line 628: /Users/jenkins/workspace/Grinder/openjdkbinary/j2sdk-image/bin/java: cannot execute binary file
05:14:25  =JAVA VERSION OUTPUT END=
05:14:25  =RELEASE INFO BEGIN=
05:14:25  IMPLEMENTOR="Eclipse Adoptium"
05:14:25  IMPLEMENTOR_VERSION="Temurin-19.0.1+10"
05:14:25  JAVA_VERSION="19.0.1"
05:14:25  JAVA_VERSION_DATE="2022-10-18"
05:14:25  LIBC="gnu"
05:14:25  MODULES="java.base java.compiler java.datatransfer java.xml java.prefs java.desktop java.instrument java.logging java.management java.security.sasl java.naming java.rmi java.management.rmi java.net.http java.scripting java.security.jgss java.transaction.xa java.sql java.sql.rowset java.xml.crypto java.se java.smartcardio jdk.accessibility jdk.internal.jvmstat jdk.attach jdk.charsets jdk.zipfs jdk.compiler jdk.crypto.ec jdk.crypto.cryptoki jdk.dynalink jdk.internal.ed jdk.editpad jdk.hotspot.agent jdk.httpserver jdk.incubator.concurrent jdk.incubator.vector jdk.internal.le jdk.internal.opt jdk.internal.vm.ci jdk.internal.vm.compiler jdk.internal.vm.compiler.management jdk.jartool jdk.javadoc jdk.jcmd jdk.management jdk.management.agent jdk.jconsole jdk.jdeps jdk.jdwp.agent jdk.jdi jdk.jfr jdk.jlink jdk.jpackage jdk.jshell jdk.jsobject jdk.jstatd jdk.localedata jdk.management.jfr jdk.naming.dns jdk.naming.rmi jdk.net jdk.nio.mapmode jdk.random jdk.sctp jdk.security.auth jdk.security.jgss jdk.unsupported jdk.unsupported.desktop jdk.xml.dom"
05:14:25  OS_ARCH="aarch64"
05:14:25  OS_NAME="Linux"
05:14:25  SOURCE=".:git:198491a37d9a"
05:14:25  BUILD_SOURCE="git:ce8eca7591182a7d05adf1a25d7feac1059c1ef2"
05:14:25  BUILD_SOURCE_REPO="https://github.com/adoptium/temurin-build.git"
05:14:25  SOURCE_REPO="https://github.com/adoptium/jdk19u.git"
05:14:25  FULL_VERSION="19.0.1+10"
05:14:25  SEMANTIC_VERSION="19.0.1+10"
05:14:25  BUILD_INFO="OS: Linux Version: 5.4.0-110-generic"
05:14:25  JVM_VARIANT="Hotspot"
05:14:25  JVM_VERSION="19.0.1+10"
05:14:25  IMAGE_TYPE="JDK"
05:14:25  =RELEASE INFO END=

https://ci.adoptopenjdk.net/job/Grinder/5894/console

@sophia-guo
Copy link
Contributor Author

sophia-guo commented Nov 15, 2022

again https://ci.adoptopenjdk.net/job/Grinder/6200/console. jdk download seems good, it might be machine configure issue for not find java but it helps if there is failure then exit.

14:11:04  _ENCODE_FILE_NEW=UNTAGGED curl -OLJSks  https://api.adoptium.net/v3/binary/latest/8/ea/linux/arm/jdk/hotspot/normal/adoptium?project=jdk
14:11:05  Uncompressing file: OpenJDK8U-jdk_arm_linux_hotspot_2022-11-14-12-37.tar.gz ...
14:11:07  Run /home/jenkins/workspace/Grinder/openjdkbinary/j2sdk-image/bin/java -version
14:11:07  =JAVA VERSION OUTPUT BEGIN=
14:11:07  ./get.sh: line 628: /home/jenkins/workspace/Grinder/openjdkbinary/j2sdk-image/bin/java: No such file or directory
14:11:07  =JAVA VERSION OUTPUT END=
14:11:07  =RELEASE INFO BEGIN=
14:11:07  JAVA_VERSION="1.8.0_362"
14:11:07  OS_NAME="Linux"
14:11:07  OS_VERSION="2.6"
14:11:07  OS_ARCH="aarch32"
14:11:07  SOURCE=".:git:d21ce51f5e94+"
14:11:07  IMPLEMENTOR="Eclipse Adoptium"
14:11:07  BUILD_SOURCE="git:897657a2be785c7f17cfc723a084ae90fac2ef45"
14:11:07  BUILD_SOURCE_REPO="https://github.com/adoptium/temurin-build.git"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Development

Successfully merging a pull request may close this issue.

1 participant