Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » P2 » Eclipse can't load all bundles after upgraded to eclipse 4.10
Eclipse can't load all bundles after upgraded to eclipse 4.10 [message #1800936] Thu, 10 January 2019 02:46 Go to next message
meng chao is currently offline meng chaoFriend
Messages: 8
Registered: January 2019
Junior Member
After I upgraded the target platform of my product from eclipse4.3 to eclipse4.10, my product can't load all bundles in the plugins folder by default anymore, could you please tell me how to configure eclipse4.10 to load all bundles in the plugins folder by default except using org.eclipse.equinox.simpleconfigurator and bundles.info ?

When using eclipse4.3 as target platform, I can configure eclipse to load all bundles by default through configuring the following codes in config.ini:
osgi.bundles=org.eclipse.equinox.common@2:start,org.eclipse.update.configurator@3:start,org.eclipse.equinox.ds@2:start,org.eclipse.core.runtime@start

but after I upgraded my target platform to eclipse4.10, it doesn't work anymore.

Thanks in advance,
Chao

[Updated on: Thu, 10 January 2019 04:02]

Report message to a moderator

Re: Eclipse can't load all bundles after upgraded to eclipse 4.10 [message #1800939 is a reply to message #1800936] Thu, 10 January 2019 03:54 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 30646
Registered: July 2009
Senior Member
I know we had to change this in Oomph's product definition because org.eclipse.equinox.ds has been removed from the platform's feature(s):
      <plugin id="org.apache.felix.scr" autoStart="true" startLevel="2" />
I.e., believe org.apache.felix.scr is the placement for org.eclipse.equinox.ds for starting the services early.
Re: Eclipse can't load all bundles after upgraded to eclipse 4.10 [message #1800941 is a reply to message #1800939] Thu, 10 January 2019 06:40 Go to previous messageGo to next message
meng chao is currently offline meng chaoFriend
Messages: 8
Registered: January 2019
Junior Member
Thanks for your reply Ed,

My RCP doesn't use Oomph, so I tried to replace the org.eclipse.equinox.ds with org.apache.felix.scr in osgi.bundles attribute, but it still launch failed.

BR
Chao

[Updated on: Thu, 10 January 2019 07:32]

Report message to a moderator

Re: Eclipse can't load all bundles after upgraded to eclipse 4.10 [message #1800960 is a reply to message #1800941] Thu, 10 January 2019 11:14 Go to previous messageGo to next message
meng chao is currently offline meng chaoFriend
Messages: 8
Registered: January 2019
Junior Member
Is org.eclipse.equinox.simpleconfigurator / bundles.info the only way to control to load bundles?
(Except writing all bundles into the osgi.bundles attribute)

[Updated on: Thu, 10 January 2019 11:17]

Report message to a moderator

Re: Eclipse can't load all bundles after upgraded to eclipse 4.10 [message #1800976 is a reply to message #1800960] Thu, 10 January 2019 14:25 Go to previous messageGo to next message
Brian de Alwis is currently offline Brian de AlwisFriend
Messages: 857
Registered: January 2012
Senior Member

Generally OSGi only loads bundles that were explicitly specified (i.e., in the osgi.bundles property or via other means like the simpleconfigurator). The update.configurator was a bit of a hack and caused other bad behaviour such as updated or removed bundles being reloaded. The update.configurator behaviour was gutted due to bug 527783.

How are you building and assembling your app?


Eclipse Platform committer. Ask me about Eclipse support, training, and consulting.
Re: Eclipse can't load all bundles after upgraded to eclipse 4.10 [message #1801010 is a reply to message #1800976] Fri, 11 January 2019 03:31 Go to previous messageGo to next message
meng chao is currently offline meng chaoFriend
Messages: 8
Registered: January 2019
Junior Member
Thank you very much!

I am not very sure what do you mean about "How are you building and assembling your app?", before we used a customized config.ini and configured it to load all bundles in the plugins folder.
We'll change our system to generate the bundles.info.

BR
Chao
Re: Eclipse can't load all bundles after upgraded to eclipse 4.10 [message #1801044 is a reply to message #1801010] Fri, 11 January 2019 15:53 Go to previous messageGo to next message
Brian de Alwis is currently offline Brian de AlwisFriend
Messages: 857
Registered: January 2012
Senior Member

I meant are you using Maven/Tycho, or PDE Build, or some other technology?

You could also consider using the org.eclipse.equinox.p2.reconciler.dropins bundle, which is like the org.eclipse.update.configurator but installs all bundles found in the dropins/ folder.


Eclipse Platform committer. Ask me about Eclipse support, training, and consulting.
Re: Eclipse can't load all bundles after upgraded to eclipse 4.10 [message #1801105 is a reply to message #1801044] Mon, 14 January 2019 03:15 Go to previous messageGo to next message
meng chao is currently offline meng chaoFriend
Messages: 8
Registered: January 2019
Junior Member
Yes, we are using Maven/Tycho; I'll check the org.eclipse.equinox.p2.reconciler.dropins bundle.

Thank you!
Chao
Re: Eclipse can't load all bundles after upgraded to eclipse 4.10 [message #1801159 is a reply to message #1801105] Mon, 14 January 2019 17:31 Go to previous messageGo to next message
Phil Beauvoir is currently offline Phil BeauvoirFriend
Messages: 51
Registered: October 2012
Member
Just ran into this problem. See https://github.com/archimatetool/archi/issues/429

Our RCP app uses a custom method of adding plugins to the "plugins" folder and doesn't use P2 for this. Therefore using the simpleconfigurator is not an option.

How easy/hard would it be to use org.eclipse.equinox.p2.reconciler.dropins and the dropins folder? Does our RCP app need to do anything special?
Re: Eclipse can't load all bundles after upgraded to eclipse 4.10 [message #1801166 is a reply to message #1801159] Mon, 14 January 2019 18:42 Go to previous messageGo to next message
Brian de Alwis is currently offline Brian de AlwisFriend
Messages: 857
Registered: January 2012
Senior Member

See the p2 Getting Started guide for details on dropins:

https://wiki.eclipse.org/Equinox/p2/Getting_Started#Dropins

But the simple answers are: "easy" and "just include the bundle and mkdir dropins/" :-)

Do realize though that officially the dropins is deprecated and not recommended. And be sure to read the section in the Getting Started guide on debugging dropins.

Brian.


Eclipse Platform committer. Ask me about Eclipse support, training, and consulting.
Re: Eclipse can't load all bundles after upgraded to eclipse 4.10 [message #1809397 is a reply to message #1801166] Mon, 15 July 2019 13:05 Go to previous messageGo to next message
Jan Pesta is currently offline Jan PestaFriend
Messages: 4
Registered: July 2019
Junior Member
Is there a way to force upsate/simple configurator to retake bundles from plugins folder?

we are creating RCP application with a maven, and actually time to time we need to patch existing application with new bundle version, but it is now ignored.

Is there a way to instruct any configurator to take new version of bundle?

Thanks
Re: Eclipse can't load all bundles after upgraded to eclipse 4.10 [message #1809468 is a reply to message #1809397] Tue, 16 July 2019 14:00 Go to previous messageGo to next message
Brian de Alwis is currently offline Brian de AlwisFriend
Messages: 857
Registered: January 2012
Senior Member

The recommended way is to use p2 to download and apply changes. You can use p2 programmatically through its API. The p2 FAQ has some pointers.

Eclipse Platform committer. Ask me about Eclipse support, training, and consulting.
Re: Eclipse can't load all bundles after upgraded to eclipse 4.10 [message #1809504 is a reply to message #1801166] Wed, 17 July 2019 06:34 Go to previous messageGo to next message
Jan Pesta is currently offline Jan PestaFriend
Messages: 4
Registered: July 2019
Junior Member
Hi,

I have looked into that, but as the build features contains exact version of bundles, and If I try to use provinstall with newer version of bundle, it give me error that dependency to old version can not be satisfied, so product could not beresolved.

Actually we are building about 100+ bundles, so it make no sense to install newer feature as it would update much more bundles than the only one, and we have requirement to allow really small patches.

Or is there a way to generate bundle.info property without versions? I remember that with PDE it was possible, but with tycho I didn't found a way to do it.

Thanks in advance.





Re: Eclipse can't load all bundles after upgraded to eclipse 4.10 [message #1809808 is a reply to message #1809504] Tue, 23 July 2019 18:30 Go to previous messageGo to next message
Brian de Alwis is currently offline Brian de AlwisFriend
Messages: 857
Registered: January 2012
Senior Member

Take a look at feature patches.

Eclipse Platform committer. Ask me about Eclipse support, training, and consulting.
Re: Eclipse can't load all bundles after upgraded to eclipse 4.10 [message #1811303 is a reply to message #1809808] Fri, 30 August 2019 10:28 Go to previous messageGo to next message
Jan Pesta is currently offline Jan PestaFriend
Messages: 4
Registered: July 2019
Junior Member
Hi again,
Thanks for feature patches. They do exactly what I wanted, but unfortunately it is only one time patch.

I have also tryied to uninstall that patch later and It fails as it could not find original version of patched bundle - which is located in plugins folder.

I think problem is that when tycho materialize product, it keeps original sites there (local folders on build machine), and p2 does not have those folders available when uninstalling feature patch.

Is there a way to inform p2 to check plugins/features folders for existing bundles?
Re: Eclipse can't load all bundles after upgraded to eclipse 4.10 [message #1811309 is a reply to message #1811303] Fri, 30 August 2019 12:54 Go to previous messageGo to next message
Jan Pesta is currently offline Jan PestaFriend
Messages: 4
Registered: July 2019
Junior Member
Just find out that you can install new version of patch when you directly uninstall older version in that step - there is not problem with missing plugins as you will replace them directly.
Re: Eclipse can't load all bundles after upgraded to eclipse 4.10 [message #1811323 is a reply to message #1811309] Fri, 30 August 2019 19:58 Go to previous message
Brian de Alwis is currently offline Brian de AlwisFriend
Messages: 857
Registered: January 2012
Senior Member

There I another alternative: the dropins/ folder. It's officially deprecated though still available, and not recommended for a variety of reasons, especially when you have hundreds of bundles -- managing conflicts can be hairy and you may end up with untested combinations. Whereas features let you manage a set of tested combinations.

Eclipse Platform committer. Ask me about Eclipse support, training, and consulting.
Previous Topic:How to get correct version jre number generated in eclipse.ini
Next Topic:Good place for hosting p2 repositories
Goto Forum:
  


Current Time: Tue Nov 19 18:56:04 GMT 2019

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

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

Back to the top