Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » How to deliver updates for fragments with OSGi hooks?
icon5.gif  How to deliver updates for fragments with OSGi hooks? [message #1231674] Wed, 15 January 2014 07:23 Go to next message
Denis Golovin is currently offline Denis GolovinFriend
Messages: 18
Registered: July 2009
Junior Member
Is there any way to deliver updates for fragments with OSGi hooks?

Lets say I have developed OSGi hook and it is included into feature available from my update site. I have configured p2 touchpoint to add

-Dosgi.framework.extensions=reference:file:org.domain.feature_1.0.0.vXXXXXXXX-XXXX.jar

into eclipse.ini to activate my hook when eclipse restarted after installation.

But there are several problems with this approach:
1. How do I deal with scenario when there is another hook(s) already configured in eclipse.ini?
2. If i need to deliver update for a fragment with OSGi hook implementation how do I update my fragment reference in osgi.framework.extensions system property?

[Updated on: Wed, 15 January 2014 08:06]

Report message to a moderator

Re: How to deliver updates for fragments with OSGi hooks? [message #1231677 is a reply to message #1231674] Wed, 15 January 2014 07:27 Go to previous messageGo to next message
Thomas Schindl is currently offline Thomas SchindlFriend
Messages: 6651
Registered: July 2009
Senior Member
p2 recognizes this itself so there's no touch point needed - it will
push the information into the config.ini! At least this works for me
flawlessly for e(fx)clipse updates.

I only had one problem lately which involves Kepler SR 1 and the
p2-directory app which does not update the config.ini.

Tom

On 15.01.14 08:23, Denis Golovin wrote:
> Is there any way to deliver updates for fragments with OSGi hooks?
>
> Lets say I have developed OSGi hook and it is included into feature
> available from my update site. I have configured p2 touchpoint to add
>
> -Dosgi.framework.extensions=reference:file:org.domain.feature_1.0.0.vXXXXXXXX-XXXX.jar
>
>
> into eclipse.ini to activate my hook when eclipse restarted after
> installation.
>
> But there are several problems with this approach:
> 1. How do I deal with scenario when there is another hook(s) already
> configured in eclipse.ini?
> 2. If i need to deliver update for a fragment with OSGi hook
> implementation how do I update my fragment reference in
> osgi.framework.extensions system property?
>
>
Re: How to deliver updates for fragments with OSGi hooks? [message #1231684 is a reply to message #1231677] Wed, 15 January 2014 07:40 Go to previous messageGo to next message
Denis Golovin is currently offline Denis GolovinFriend
Messages: 18
Registered: July 2009
Junior Member
Tom,

do you mean when I fix the problem and build new version I don't need to do any efforts to update reference to hook's jar in config.ini?

Does this work in luna?

Thanks
Re: How to deliver updates for fragments with OSGi hooks? [message #1231685 is a reply to message #1231684] Wed, 15 January 2014 07:44 Go to previous messageGo to next message
Max Rydahl Andersen is currently offline Max Rydahl AndersenFriend
Messages: 233
Registered: July 2009
Senior Member
Tom,

Do you know of any docs for this and how does it work if there are two plugins wanting to install osgi hooks ?

i.e. e(fx)clipse and jbosstools both add hooks ?

are you saying that p2 will recognize and configure the osgihook's without any touchpoint at all ?
Re: How to deliver updates for fragments with OSGi hooks? [message #1231705 is a reply to message #1231684] Wed, 15 January 2014 08:29 Go to previous messageGo to next message
Thomas Schindl is currently offline Thomas SchindlFriend
Messages: 6651
Registered: July 2009
Senior Member
Right you don't have to adjust the eclipse.ini because p2 will add the
information to the config.ini automagically!

Tom

On 15.01.14 08:40, Denis Golovin wrote:
> Tom,
>
> do you mean when I fix the problem and build new version I don't need to
> do any efforts to update reference to hook's jar in config.ini?
>
> Does this work in luna?
>
> Thanks
Re: How to deliver updates for fragments with OSGi hooks? [message #1231709 is a reply to message #1231685] Wed, 15 January 2014 08:30 Go to previous message
Thomas Schindl is currently offline Thomas SchindlFriend
Messages: 6651
Registered: July 2009
Senior Member
I would at least hope it would - I can't provide you with docs and was
suprised myself that p2 figures this out itself.

I guess easiest is propably to locate the hookconfigurators.properties
string in p2 source because this is the only way it can detect the
bundle is a hook one.

Tom

On 15.01.14 08:44, Max Rydahl Andersen wrote:
> Tom,
> Do you know of any docs for this and how does it work if there are two
> plugins wanting to install osgi hooks ?
>
> i.e. e(fx)clipse and jbosstools both add hooks ?
> are you saying that p2 will recognize and configure the osgihook's
> without any touchpoint at all ?
>
Previous Topic:Kepler OEPE and Weblogic Portal
Next Topic:Eclipse freezes system during debugging in Linux
Goto Forum:
  


Current Time: Thu Apr 25 22:57:29 GMT 2024

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

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

Back to the top