On Fri, Nov 19, 2010 at 2:10 PM, Felix Meschberger <[email protected]>wrote:

> In your case, the problem is that you have some configuration which must
> instantiate some more-or-less random class. I agree with Neil, that it
> would probably best if you forget about DS and....
>
>  * Implement a ManagedServiceFactory listeing for the configurations
>  * Instantiate (and destory) your service instances yourself
>  * Register/unregister the services instances along the way
>
> I don't think you need to use Service Tracker, though.
>
> The clients of your class can still be implemented as DS components
> referring to the dynamically created and registered services. Its just
> provisioning of the services that is not handled by DS.
>

Thant's exactly what I have done already :-).

It would just be a nice feature if my example worked as is. This way DS
would still save some lines of the code.

Thanks for your answers.
-- 
Ing. Martin Ždila
CTO

M-Way Solutions Slovakia s.r.o.
Letná 27, 040 01 Košice
Slovakia

tel:+421-908-363-848
mailto:[email protected]
http://www.mwaysolutions.com
_______________________________________________
OSGi Developer Mail List
[email protected]
https://mail.osgi.org/mailman/listinfo/osgi-dev

Reply via email to