DS and Spring beans [message #540112] |
Tue, 15 June 2010 00:29 |
|
We have a mix of OSGi DS services (Declarative Services components) and
Spring beans and services. Is it possible to use a Spring bean as a
property of a DS service, i.e. inject the Spring bean into the DS
service? Would it help if the Spring bean were declared as a service
using Spring DM?
Craig
|
|
|
|
Re: DS and Spring beans [message #540306 is a reply to message #540169] |
Tue, 15 June 2010 15:13 |
|
Thanks for replying Stefan, this looks promising.
Regarding exposing a Spring bean as a DM service and consuming it in a DS component service, do you have an example?
Does the DS XML declaration reference the DM service by id or interface? Does the resolution of that dependency require the bundle declaring the Spring bean be started? If so, how should it be started?
I like DS in that the first consumer of the service starts the service bundle automagically while I had problems with DM services not being available if the declaring bundle is not somehow started.
Any help greatly appreciated!
Craig
[Updated on: Wed, 16 June 2010 00:44] Report message to a moderator
|
|
|
|
Powered by
FUDForum. Page generated in 0.03520 seconds