Community
Participate
Working Groups
When an IApplication extension point is specified as thread="any", it cannot be run from the launcher. If you attempt to run it, it gives an error message as below. However, this is misleading. In fact, the application *does* run; as can be seen by the output to the Console. The framework, however, thinks that it hasn't started, and so kills the platform (which then shuts down the application). I've put together a test app with 3 example apps; they're all the same code (which prints out "Hello World", then "waiting" (sleep 1) "almost there" (sleep 1) "done". I've also included the launch configurations for same; TestApp-any, Test-App-main and TestApp-default that have thread="any", thread="main" and one without thread. Running 'TestApp-any' shows the printout of the app starting, but gives the error message below, whilst default and main work successfully. If thread=main, then aren't you limited to 1 instance of the app? It certainly seems to indicate that in the docs. If you want your app to play nicely and be fine with running outside of the main thread, then it seems you can't launch this from the command line. java.lang.IllegalStateException: Unable to acquire application service. Ensure that the org.eclipse.core.runtime bundle is resolved and started (see config.ini). at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:72) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:363) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:176) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:504) at org.eclipse.equinox.launcher.Main.basicRun(Main.java:443) at org.eclipse.equinox.launcher.Main.run(Main.java:1169) at org.eclipse.equinox.launcher.Main.main(Main.java:1144)
Created attachment 73136 [details] Provides a demo project to demonstrate the differences with thread=any/main Run ThreadMain or ThreadDefault launches, and it works. Run ThreadAny, and whilst it's clear the application is launched, the framework doesn't think so and so shuts it down.
Alex, please try the patch in bug 193596. *** This bug has been marked as a duplicate of bug 193596 ***
Yeah, closing as dupe.