Cannot start osgi container (equinox) inside eclipse

I installed Eclipse Juno Service Release 2. I am trying to learn OSGi using the Equinox container in eclipse. However, when I try to start Equinox from the command line using the following code, it does not start. Can someone please let me know what is missing here?

java -jar org.eclipse.osgi_3.8.2.v20130124-134944.jar -console 

Thanks!

+4
source share
2 answers

I ran into the same problem, moving from 3.5 to 3.8.2. They changed the implementation of the console, which now relies on the felix gogo project . You will need to start the following packages along with the standard equinox:

  • org.eclipse.equinox.console_1.0.100.v20121001-124408.jar
  • org.apache.felix.gogo.shell_0.10.0.v201211091412.jar
  • org.apache.felix.gogo.runtime_0.10.0.v201209301036.jar
  • org.apache.felix.gogo.command_0.10.0.v201209301215.jar

You can add them to the bundle list to start by default in the config.ini file as follows:

 #contents of config.ini osgi.b undles=org.eclipse.equinox.console_1.0.100.v20121001-124408.jar@ start, org.apache.felix.gogo.shell_0.10.0.v201211091412.jar@start , org.apache.felix.gogo.runtime_0.10.0.v201209301036.jar@start , org.apache.felix.gogo.command_0.10.0.v201209301215.jar@start 

Your directory structure should be

 - org.eclipse.osgi_3.8.2.v20130124-134944.jar - configuration/ config.ini 
+3
source

Yes, I see the same behavior. After reading some of the beginning tutorials (yes, I'm new :-) on OSGi with Equinox for beginners: console, launcher and configuration I found that the logs are sent to the log files by default and the -consoleLog parameter is used to view them in standard mode

 java -jar org.eclipse.osgi_3.8.2.v20130124-134944.jar -console -consoleLog 

What then tells me the message

 org.osgi.framework.BundleException: Could not find bundle: org.eclipse.equinox.console 

I searched for what brought me here: org.osgi.framework.BundleException: Could not find package: org.eclipse.equinox.console . I have not tried it, but it looks like you need a solution.

+1
source

Source: https://habr.com/ru/post/1479838/


All Articles