felix-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher BROWN <br...@reflexe.fr>
Subject Re: declarative Services
Date Sun, 02 Jun 2013 07:54:09 GMT
Hi Peter,

Isn't that a bit like asserting that you only ever need functional
programming, and not OOP or any other imperative style?

I would tend to agree with your assertion, where DS is the best fit
solution for most use cases, but having the bundle activator is nice in
order to handle edge cases.

--
Christopher



On 1 June 2013 11:27, Peter Kriens <peter.kriens@aqute.biz> wrote:

> If I had to start over with the design of OSGi there would be no bundle
> activator, just DS components ... The activator was a mistake since it is a
> singleton and I now sometimes wonder what we are smoking, forcing people to
> handle their own service dependencies. DS's support services, service
> factories, and more as well as fully handling service dependencies makes
> services as lightweight as classes. With the DS annotations you can turn ay
> class into a service (factory) whenever you want, not requiring any extra
> setup. I found it amazing how light weight services became once I could do
> this.
>
> You can control the life cycle of the component with config admin using
> managed service (factories). Config admin can define/override service
> properties and define which service dependencies are bound by setting the
> target filter.
>
> With DS you do not need the dependency manager since DS handles deps for
> you.
>
> Again, OSGi was not complete until DS was specified.
>
> Kind regards,
>
>     Peters Kriens

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message