Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Equinox » Standard OSGi launch configuration Equinox 3.11(Is it still possible to run an standard OSGi in Eclipse 4.5?)
Standard OSGi launch configuration Equinox 3.11 [message #1712695] Tue, 27 October 2015 13:54 Go to next message
Pablo Gomez is currently offline Pablo GomezFriend
Messages: 28
Registered: October 2013
Junior Member
Hello!
I have a small -I hope- issue. The target is just to run from eclipse IDE an OSGi standard application. That means, no P2, no emf, no swt just an standard OSGi.
Well, I'm able to do so up to Eclipse Luna SR2. However, I do not know what I'm doing wrong with Mars SR1 (Equinox 3.11)
In Luna to run a standard osgi app I only need to set up the launch config as follows:


  1. org.eclipse.osgi
  2. org.apache.felix.gogo.command
  3. org.apache.felix.gogo.runtime
  4. org.apache.felix.gogo.shell
  5. org.eclipse.equinox.console


And that's it, nothing more. However, doing so in Mars I get the following exception:
java.lang.IllegalStateException: Unable to acquire application service. Ensure that the org.eclipse.core.runtime bundle is resolved and started (see config.ini). Which I do not understand because in Luna this is not necessary to have the core.runtime bundle installed. As a consequence of installing that bundle, I need additionally to install a few others like:

  1. org.eclipse.core.contenttype
  2. org.eclipse.core.jobs
  3. org.eclipse.core.equinox.app
  4. org.eclipse.core.equinox.common
  5. org.eclipse.core.equinox.preferences
  6. org.eclipse.core.equinox.registry

Which I also do not understand very well why are required, I only want to deploy a standard osgi application in an equinox container. Sadly, If I resolve all the dependencies I end up with an application id not found exception and the equinox container simply shuts down... This application id requirement is confusing me because that id should be required when running an eclipse application but not when the application is a standard osgi one.

So do you guys think there is a bug here? and if not, what I'm doing wrong? How am I suppose to run a standard osgi on equinox? Or is it not possible anymore?

Thanks!
Regards
Pablo
Re: Standard OSGi launch configuration Equinox 3.11 [message #1712722 is a reply to message #1712695] Tue, 27 October 2015 17:03 Go to previous messageGo to next message
Pascal Rapicault is currently offline Pascal RapicaultFriend
Messages: 333
Registered: July 2009
Location: Ottawa
Senior Member
I just created a launch configuration with the bundles you mention and I've been able to start the app just fine.
(see screenshot)
Be sure to create a launch configuration of type "OSGi Framework"
Re: Standard OSGi launch configuration Equinox 3.11 [message #1712726 is a reply to message #1712695] Tue, 27 October 2015 17:17 Go to previous messageGo to next message
Pablo Gomez is currently offline Pablo GomezFriend
Messages: 28
Registered: October 2013
Junior Member
I've tried now with only these 4 bundles -no bundle in the workspace-

org.eclipse.osgi
org.apache.felix.gogo.command
org.apache.felix.gogo.runtime
org.apache.felix.gogo.shell
org.eclipse.equinox.console

And no luck. By the way I'm testing on a Windows 10 machine
and Java(TM) SE Runtime Environment (build 1.8.0_66-b17)

see attached pictures



Anyway I will retry with a new workspace with no bundles, just the 5 I've mentioned. I'll try too with a linux machine case that makes a difference
  • Attachment: mars.PNG
    (Size: 216.05KB, Downloaded 497 times)
  • Attachment: target.PNG
    (Size: 111.72KB, Downloaded 629 times)

[Updated on: Tue, 27 October 2015 17:17]

Report message to a moderator

Re: Standard OSGi launch configuration Equinox 3.11 [message #1712728 is a reply to message #1712726] Tue, 27 October 2015 17:29 Go to previous messageGo to next message
Pascal Rapicault is currently offline Pascal RapicaultFriend
Messages: 333
Registered: July 2009
Location: Ottawa
Senior Member
I highly suspect that somewhere on the CLI you have -application or something like that.

Here are screenshots of my configuration. Aside from the list of bundles that I have changed to only include the 5 bundles, everything else contains the default parameters. However know that those are generated from the target plaform, and my target platform is different than yours.
  • Attachment: Args.png
    (Size: 47.42KB, Downloaded 671 times)
  • Attachment: Settings.png
    (Size: 53.93KB, Downloaded 502 times)
Re: Standard OSGi launch configuration Equinox 3.11 [message #1712743 is a reply to message #1712695] Tue, 27 October 2015 20:07 Go to previous message
Pablo Gomez is currently offline Pablo GomezFriend
Messages: 28
Registered: October 2013
Junior Member
ok, I found out the problem, the thing was that it seems necessary to provide the following arguments to the VM:

-Declipse.ignoreApp=true -Dosgi.noShutdown=true

and in my case that was missing and I certainly was not aware about the need of such a flags. But now it works Smile
Thanks
regards
Pablo

[Updated on: Tue, 27 October 2015 20:08]

Report message to a moderator

Previous Topic:org.eclipse.equinox.http.servlet 1.2.0.v20150519-1816 NOT compatible to javax.servlet 2.3.0
Next Topic:Development of dropins bundle deployment capability
Goto Forum:
  


Current Time: Sat Oct 05 03:54:47 GMT 2024

Powered by FUDForum. Page generated in 0.05168 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top