Elias recently blogged about about the ‘OSGi for Eclipse Developers‘ presentation I gave. There’s been some commentary about Eclipse plug-ins not being OSGi bundles. It was mostly spurred by this slide:
What we were trying to convey with this picture is that the OSGi and Eclipse communities tend to argue over a name. In the end, it’s still the same thing. Let me repeat, an Eclipse plug-in is an OSGi bundle and vice-versa. If anyone tells you otherwise, they are lying. There are people that like to claim that since Eclipse folks tend to heavily use the Extension Registry (i.e., plugin.xml) that they aren’t a bundle. The Extension Registry is simply another OSGi service and really just a feature built on top of the wonderful OSGi service registry. The Extension Registry also runs on other OSGi frameworks like Felix (it can even run outside of OSGi if you want). It’s no different than the Declarative Services (DS) bundles or Spring DM bundles (well I guess DS is in the OSGi specification). The only issue that you have to watch out for when developing a bundle is being tied to a framework. In Eclipse land, we have some special manifest headers (e.g., Eclipse-BuddyPolicy) that may not work in other frameworks. This isn’t really an Eclipse specific issue, other frameworks suffer from the same fate if they invent manifest headers. It’s still an OSGi bundle in the end.
What have people experienced out in the field regarding this debate? Anything? Any ideas on how to make things better?
In the end, what we were trying to say that the communities need to stop bickering and focus on the goal of getting more people on OSGi:
On a somewhat related note, the more important message in that presentation was that services are dynamic and you need to get in your head. I know programming for dynamics is hard but you just need to remember that terrible Culuture Club song when you think of OSGi services… you come and go! Anticipate dynamics and use things like Declarative Services to make your life easier.
And now I can’t get that song out of my head ;)