Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » P2 » OSGI Service Problem after update a feature
OSGI Service Problem after update a feature [message #787277] Tue, 31 January 2012 11:44 Go to next message
Christian Eugster is currently offline Christian EugsterFriend
Messages: 214
Registered: July 2009
Location: St. Gallen Switzerland
Senior Member
Hi, maybe someone can help: I added p2 install/update to my 3.6.2 rcp application and updated this application by installing a new feature (1.0.0.qualifier), containing an osgi service, from my update site. Then I added a new version (1.0.1.qualifier) of that feature to the update site and updated my application with that new version feature. After that an exception is thrown, saying, that two services with the same name are installed. How I have to update a feature containing an osgi service, so that no service clash is the result? Thank you very much for any idea!

Christian Eugster
Re: OSGI Service Problem after update a feature [message #787992 is a reply to message #787277] Wed, 01 February 2012 08:05 Go to previous messageGo to next message
Christian Eugster is currently offline Christian EugsterFriend
Messages: 214
Registered: July 2009
Location: St. Gallen Switzerland
Senior Member
Hi, maybe, I have been a little unclear, what the problem is: I have a rcp application with install/update capability using p2. I create a plugin (say plugin1.0.0.qualifier) with an osgi service component installable with p2. I install this plugin. After a while I add functionality to this plugin1.0.0.qualifier, so creating another plugin (plugin1.0.1.qualifier), also installable throught p2. Now, I update my application (downloading and installing plugin1.0.1.qualifier) and restart the application. After a while I get in the console the message, that two service components with the same name (service 1 from plugin1.0.0.qualifier and service 2 from plugin1.0.1.qualifier) are found. ss plugin shows that both plugins are active. In my oppinion that not should be the case. What is going wrong here?

Thank you for answering!

Christian Eugster
Re: OSGI Service Problem after update a feature [message #788085 is a reply to message #787992] Wed, 01 February 2012 10:35 Go to previous messageGo to next message
Henrik Lindberg is currently offline Henrik LindbergFriend
Messages: 2509
Registered: July 2009
Senior Member
Unless a bundle is a singleton, you are allowed to install multiple
versions. If when you say you "update", you actually "install" the new
version, this is exactly what you get. If you instead perform an update
p2 replaces the older version with the newer.

Regards
- henrik

On 2012-01-02 9:05, Christian Eugster wrote:
> Hi, maybe, I have been a little unclear, what the problem is: I have a
> rcp application with install/update capability using p2. I create a
> plugin (say plugin1.0.0.qualifier) with an osgi service component
> installable with p2. I install this plugin. After a while I add
> functionality to this plugin1.0.0.qualifier, so creating another plugin
> (plugin1.0.1.qualifier), also installable throught p2. Now, I update my
> application (downloading and installing plugin1.0.1.qualifier) and
> restart the application. After a while I get in the console the message,
> that two service components with the same name (service 1 from
> plugin1.0.0.qualifier and service 2 from plugin1.0.1.qualifier) are
> found. ss plugin shows that both plugins are active. In my oppinion that
> not should be the case. What is going wrong here?
>
> Thank you for answering!
>
> Christian Eugster
Re: OSGI Service Problem after update a feature [message #788875 is a reply to message #788085] Thu, 02 February 2012 10:16 Go to previous message
Christian Eugster is currently offline Christian EugsterFriend
Messages: 214
Registered: July 2009
Location: St. Gallen Switzerland
Senior Member
Hi Henrik, that was it! Thank you for your answer!
Previous Topic:Problem with feature patch
Next Topic:Basic packages like jface or swt in eclipse p2 repositories - ?
Goto Forum:
  


Current Time: Sat Dec 14 16:22:38 GMT 2024

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

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

Back to the top