2

Recently I have upgraded my eclipse to 4.7 to support Java9 After upgradation eclipse not loading pre-existing java application. When I check run as run as > run configuration and double clicks on java application it throws

An error has occurred. See error log for more details. tried to access method org.eclipse.debug.internal.ui.launchConfigurations.LaunchConfigurationsDialog.getTabViewer()Lorg/eclipse/debug/internal/ui/launchConfigurations/LaunchConfigurationTabGroupViewer; from class org.eclipse.jdt.internal.debug.ui.launcher.LocalJavaApplicationTabGroup

Above error is gone after I downloaded eclipse-oxygen1-a(which support java9 without any plugin) but still not able to run as java application. Getting this error on console

Error: Could not find or load main class 
       com.myclass.MyApplication
       Caused by: java.lang.ClassNotFoundException: 
                  com.myclass.MyApplication

I checked the error by built-in ErrorLog of Eclipse

Window -> Show View -> General -> Error Log

Getting the following error

Session Data

eclipse.buildId=4.7.1.M20170922-1005
java.version=9
java.vendor=Oracle Corporation
BootLoader constants: OS=linux, ARCH=x86_64, WS=gtk, NL=en_US
Framework arguments:  -product org.eclipse.epp.package.jee.product
Command-line arguments:  -data file:/home/shekhar/git/ -os linux -ws gtk -arch x86_64 -product org.eclipse.epp.package.jee.product

Plug-In: org.eclipse.jdt.launching
Severity: Error
Message: Xbootclasspath option have been removed as not supported beyond Java 8.
  • There is already a thread for this https://stackoverflow.com/questions/46452383/cant-add-java-applications-in-eclipse-run-configurations-after-upgrading-to-4-7 which is ultimatley a duplicated of another. – Naman Sep 28 '17 at 07:20
  • 1
    Possible duplicate of [Choosing JRE runtime environment in java 9 in eclipse oxygen version](https://stackoverflow.com/questions/46453241/choosing-jre-runtime-environment-in-java-9-in-eclipse-oxygen-version)...the answer there probably lists out the reason for such issue. – Naman Sep 28 '17 at 07:27
  • 2
    Unfortunately, publishing a patch feature to add Java 9 support to Oxygen.1 has introduced some complexity regarding combinations of installed versions, which has caused problems like the one reported here. While there are fixes for these problems, let me just add that the Oxygen.1a release scheduled for Oct. 11 should mend all these issues, as it is a real, patch-less release (also containing some bug fixes not contained in the patch feature). – Stephan Herrmann Oct 05 '17 at 10:00
  • @ChandraShekharYadav Did you try this with upgrading to the latest [eclipse package](https://www.eclipse.org/downloads/eclipse-packages/) Eclipse Oxygen.1a (4.7.1a) which is marked as released and supports Java 9? – Naman Oct 12 '17 at 03:45
  • @nullpointer, Yes! I upgraded to latest eclipse, already mentioned the eclipse link in the question. – shekharyadav108 Oct 12 '17 at 05:57
  • **NOTE**: when upgrading to Eclipse Oxygen.1a make sure you have no left-overs from a previously installed BETA Patch feature! To find out check if version of plug-in org.eclipse.jdt.core is 3.13.50.v20171007-0855. If it is older, look under "Installed Software", find any "BETA Patch" feature for JDT and uninstall it. – Stephan Herrmann Oct 15 '17 at 12:12

0 Answers0