Skip to main content



      Home
Home » Eclipse Projects » Equinox » OSGI Services
OSGI Services [message #46524] Tue, 01 February 2005 05:28 Go to next message
Eclipse UserFriend
Originally posted by: rschmaud.NO.SPAM.de.ibm.com

Hi,

What are the plans for supporting OSGi Services in Eclipse 3.1 or future
releases?

If I understand it right, there are currently two ways of specifying the
runtime dependencies between plugins - plugin.xml and manifest.mf. And
there are two ways of using functionality from other Plugins - extension
points and OSGi Services.

Using the extension point and plugin.xml way, the dependencies between
plugins are hard-coded, a plugin A requires a plugin B and not the
functionality or specific Java Classes or ressources. The same is true
for extension points, Plugin A depends on a specific extension point of
Plugin B. So there is no way to replace Plugin B with another Plugin
which provides the same functionality and the same extension point.

I think this would be possible with osgi, a bundle can register a
service at the registry and another bundle can get this service from the
registry without having explicit dependency on the providing bundle.
They only have to share the interface of the service (which could be
provided by a third bundle).

So the only way to get loosely coupled components in eclipse is using
the OSGi Services. But I have not seen a way to register a service
without loading a plugin wich is in conflict with lazy loading.

Are there plans to migrate the extension point mechanism to the OSGI
service model or to support registring services in the manifest.mf or
the plugin.xml file?

Kind Regards
Ralf
Re: OSGI Services [message #46552 is a reply to message #46524] Wed, 02 February 2005 14:48 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: ekkehardREMOVE_NO_SPAM.gentz-software.de

hi ralf,

I'm just starting to try out osgi services and it seems to work well
using the ServiceFactory.

I'm interested to hear from the experts if there's a way of combining
lazy plugin-loading with ServiceFactories.

your idea to use an extra plugin providing the service interfaces
sounds good.

regards

ekkehard


Ralf Schmauder schrieb:
> Hi,
>
> What are the plans for supporting OSGi Services in Eclipse 3.1 or future
> releases?
>
> If I understand it right, there are currently two ways of specifying the
> runtime dependencies between plugins - plugin.xml and manifest.mf. And
> there are two ways of using functionality from other Plugins - extension
> points and OSGi Services.
>
> Using the extension point and plugin.xml way, the dependencies between
> plugins are hard-coded, a plugin A requires a plugin B and not the
> functionality or specific Java Classes or ressources. The same is true
> for extension points, Plugin A depends on a specific extension point of
> Plugin B. So there is no way to replace Plugin B with another Plugin
> which provides the same functionality and the same extension point.
>
> I think this would be possible with osgi, a bundle can register a
> service at the registry and another bundle can get this service from the
> registry without having explicit dependency on the providing bundle.
> They only have to share the interface of the service (which could be
> provided by a third bundle).
>
> So the only way to get loosely coupled components in eclipse is using
> the OSGi Services. But I have not seen a way to register a service
> without loading a plugin wich is in conflict with lazy loading.
>
> Are there plans to migrate the extension point mechanism to the OSGI
> service model or to support registring services in the manifest.mf or
> the plugin.xml file?
>
> Kind Regards
> Ralf
Re: OSGI Services [message #46785 is a reply to message #46552] Sun, 13 February 2005 15:07 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: GIWPSZBBNDAF.spammotel.com

Hello,

i had more or less the same idea. But i would not call it plugin, i must
have a special state.
An extension point (EP) should be defined by a unique name and the
interface (or set of interfaces).

The task of the framwork is now to know which EP are available and
which plugin is provider (implements the interface) and which plugin
is consumer and "connect" those plugins.

I think this would be a kind of the IoC pattern like
spring(framework.org) or picocontainer(.org) provide it and EJB3.0 will
provide it.

In this context the antipatterns of are very interesting.

Regards

Stephan Zehrer

ekkehard wrote:
> hi ralf,
>
> I'm just starting to try out osgi services and it seems to work well
> using the ServiceFactory.
>
> I'm interested to hear from the experts if there's a way of combining
> lazy plugin-loading with ServiceFactories.
>
> your idea to use an extra plugin providing the service interfaces
> sounds good.
>
> regards
>
> ekkehard
>
>
Re: OSGI Services [message #46815 is a reply to message #46785] Sun, 13 February 2005 15:10 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: GIWPSZBBNDAF.spammotel.com

Ups..

In this context the antipatterns of picocontainerare very interesting.
Take a look at http://www.picocontainer.org/Antipatterns

:)

Stephan Zehrer
Re: OSGI Services [message #46844 is a reply to message #46524] Sun, 13 February 2005 23:37 Go to previous message
Eclipse UserFriend
Originally posted by: jeff_nospam_mcaffer.ca.ibm.com

Ralf,

The extension model and the service model are complementary. It is not
possible to, in general, map one onto the other. For sure there are some
things in Eclipse that would be better off as services and I expect that
over time equivalents will be made available. I doubt however that there
will be a concerted effort to do this accross the board.

As for the (lack of ) laziness of services, OSGi R4 may contain some support
in that area. It is unclear if Eclipse will include that support.

Jeff

p.s., side notes: The manifest.mf vs plugin.xml thing is just a syntax
issue. We freely convert the execution portions of the plugin.xml to
manifest.mf. Going forward Eclipse will have only extension markup in
plugin.xml and all plugins will ship with manifest.mf files. This doesn't
actually get you anything until people start using Import-Package and
restructuring their plugins to separate out API.

p.p.s., the hardcoded dependencies were done on purpose. There is no right
answer here as both approaches have benefits and drawbacks. The pressures
pushing us that way 5 years ago were from product teams that explicitly did
not want to allow people to substitute in any old implementation of
something. They want to express the dependencies based on what they are
shipping. This produces a more rigid structure but ultimately one that is
servicable and maintainable. Going the other way allows more flexibility in
configurations etc. Poison or desert as you choose...



"Ralf Schmauder" <rschmaud@NO.SPAM.de.ibm.com> wrote in message
news:ctnlk2$j7s$1@www.eclipse.org...
> Hi,
>
> What are the plans for supporting OSGi Services in Eclipse 3.1 or future
> releases?
>
> If I understand it right, there are currently two ways of specifying the
> runtime dependencies between plugins - plugin.xml and manifest.mf. And
> there are two ways of using functionality from other Plugins - extension
> points and OSGi Services.
>
> Using the extension point and plugin.xml way, the dependencies between
> plugins are hard-coded, a plugin A requires a plugin B and not the
> functionality or specific Java Classes or ressources. The same is true
> for extension points, Plugin A depends on a specific extension point of
> Plugin B. So there is no way to replace Plugin B with another Plugin
> which provides the same functionality and the same extension point.
>
> I think this would be possible with osgi, a bundle can register a
> service at the registry and another bundle can get this service from the
> registry without having explicit dependency on the providing bundle.
> They only have to share the interface of the service (which could be
> provided by a third bundle).
>
> So the only way to get loosely coupled components in eclipse is using
> the OSGi Services. But I have not seen a way to register a service
> without loading a plugin wich is in conflict with lazy loading.
>
> Are there plans to migrate the extension point mechanism to the OSGI
> service model or to support registring services in the manifest.mf or
> the plugin.xml file?
>
> Kind Regards
> Ralf
Previous Topic:ANNOUNCEMENT - Security "Work Area" in Equinox/Eclipse
Next Topic:Extending the OSGI Console with your own commands?
Goto Forum:
  


Current Time: Sat Jul 05 08:55:14 EDT 2025

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

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

Back to the top