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

Make LookupJDKToolchainsJob detection less prone to failures #1586

Merged
merged 1 commit into from
Oct 30, 2023

Conversation

fbricon
Copy link
Contributor

@fbricon fbricon commented Oct 30, 2023

Detection should ignore errors like

!MESSAGE Process returned with error code "1".
Command line arguments: /opt/tools/java/oracle/jdk-5/latest/bin/java -Xmx16m -classpath /home/jenkins/agent/workspace/m2e-wtp_PR-28/org.eclipse.m2e.wtp.tests/target/work/configuration/org.eclipse.osgi/15/0/.cp/lib/launchingsupport.jar org.eclipse.jdt.internal.launching.support.LibraryDetector
Output: Standard output:
There was an error trying to initialize the HPI library.
Please check your installation, HotSpot does not work correctly
when installed in the JDK 1.2 Linux Production Release, or
with any JDK 1.1.x release.

Standard error:
Could not create the Java virtual machine.

!STACK 0
java.lang.IllegalStateException: Process returned with error code "1".
Command line arguments: /opt/tools/java/oracle/jdk-5/latest/bin/java -Xmx16m -classpath /home/jenkins/agent/workspace/m2e-wtp_PR-28/org.eclipse.m2e.wtp.tests/target/work/configuration/org.eclipse.osgi/15/0/.cp/lib/launchingsupport.jar org.eclipse.jdt.internal.launching.support.LibraryDetector
Output: Standard output:
There was an error trying to initialize the HPI library.
Please check your installation, HotSpot does not work correctly
when installed in the JDK 1.2 Linux Production Release, or
with any JDK 1.1.x release.

Standard error:
Could not create the Java virtual machine.

	at org.eclipse.jdt.internal.launching.StandardVMType.checkProcessResult(StandardVMType.java:932)
	at org.eclipse.jdt.internal.launching.StandardVMType.generateLibraryInfo(StandardVMType.java:730)
	at org.eclipse.jdt.internal.launching.StandardVMType.getLibraryInfo(StandardVMType.java:240)
	at org.eclipse.jdt.internal.launching.StandardVMType.getDefaultLibraryLocations(StandardVMType.java:457)
	at org.eclipse.jdt.internal.launching.StandardVMType.canDetectDefaultSystemLibraries(StandardVMType.java:267)
	at org.eclipse.jdt.internal.launching.StandardVMType.validateInstallLocation(StandardVMType.java:663)
	at org.eclipse.m2e.jdt.LookupJDKToolchainsJob.lambda$8(LookupJDKToolchainsJob.java:83)

Seen in https://ci.eclipse.org/m2e/job/m2e-wtp/view/change-requests/job/PR-28/13/artifact/org.eclipse.m2e.wtp.tests/target/work/data/.metadata/.log

Relates to eclipse-m2e/m2e-wtp#28

Change-Id: I50de3b63eecd007f5a7a92bdfe6299326ad5d634
Signed-off-by: Fred Bricon <[email protected]>
@fbricon fbricon merged commit c6fac93 into eclipse-m2e:master Oct 30, 2023
2 of 4 checks passed
@HannesWell HannesWell added this to the 2.5.0 milestone Nov 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants