Are Blueprint Services Implemented as OSGI Bundle Services?
I'm slightly confused and intrigued as to 开发者_JS百科how blueprint bundles perform dependency injection with an OSGI container.
I'm aware that plain old OSGI incorporates a service registry and bundle headings/interfaces to allow objects to be exposed to other bundles as services. Is blueprint merely an extension to this behaviour? I.e. does the blueprint extender bundle perform the underlying OSGI calls to register/get any services declared in the bundle's blueprint xml?
Yes, Blueprint will manage (among other things) the service registration for its components, using the "normal" OSGi service registry. It can interoperate with services registered using other frameworks (such as DS or hand-rolled code).
精彩评论