Hi,

You are right, 1.12.0 does not expose ManagedServiceFactory anymore because it 
uses a ‘configuration tracker’ (org.apache.felix.ipojo.ConfigurationTracker). 
The documentation is not up to date. However, the feature stay the same. 
Factory configurations pushed in the config admin create instances et support 
dynamic reconfiguration.

Depending of what you want to do, you can also rely on the Factory service 
exposed for each @Component.

Cheers,

Clement

On 13 octobre 2014 at 12:02:36, Milen Dyankov (milendyan...@gmail.com) wrote:

Hi,  
can someone point me to an example of using ConfigAdmin's  
ManagedServiceFactory with iPOJO components, please?  

The reason I'm asking is, what the docs (  
http://felix.apache.org/documentation/subprojects/apache-felix-ipojo/apache-felix-ipojo-userguide/ipojo-advanced-topics/combining-ipojo-and-configuration-admin.html)
  
say:  

For each (public) component type, a ManagedServiceFactory is published.  
> For each configurations matching with the component type from the  
> Configuration Admin, a new component instance is created.  


does not seem to work for me (iPOJO 1.12.0 in Karaf 3.0.1). No matter what  
I do, I can't get a "org.osgi.service.cm.ManagedServiceFactory" registered  
for my component.  

iPOJO will register "org.osgi.service.cm.ManagedService" for the component  
if I provide "managedservice = ..... " in the @Component and @Instantiate  
it! In such case I can indeed use ConfigAdmin to configure the instance.  

However I couldn't figure out how to instruct iPOJO to register a "  
ManagedServiceFactory" so that I can later on create new component  
instances from ConfigAdmin. Am I misinterpreting the docs? Missing  
something obvious?  

Regards,  
Milen  


--  
http://about.me/milen  

Reply via email to