felix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "John E. Conlon" <jcon...@verticon.com>
Subject Re: ServiceBinder and configuration management
Date Tue, 06 Jun 2006 19:57:53 GMT
On Tue, 2006-06-06 at 09:03 -0400, Richard S. Hall wrote:
> Also, if you are willing to play with more experimental stuff,
>  iPOJO has 
> some support for Config Admin:
> 
>     
> http://www-adele.imag.fr/~escoffie/dev/ipojo/using_iPOJO_component_model.html
> 
> Search for "Configuration" and you should find some info under the 
> "Other iPOJO features" section...
Not easy to refuse a chance to experiment with volatile substances, so I
downloaded the iPOJO plugin, bundle and tried building a iPOJO that
implements org.osgi.service.event.EventHandler and where the
event.topics property can be updated Configuration Admin.  

IPOJO seems like an easy way to do things. 

So with high hopes using the apacheDS's configurationAdmin implemenation
I configured the target bundle's event.topics to receive events from
another topic. Probably a set up snafu on my side but I couldnot pass
the new configuration to iPOJO component and get the eventHandler to
listen to a new topic.


Here is my metadata.xml

<iPOJO>	
  <component
className="com.verticon.experiment.ipojo.configuration.ConfiguribleEventHandler"
  name="com.verticon.experiment.ipojo.configuration" 
  architecture="true">

     <Provides>
        <DynamicProperty name="event.topics"
			 field="topics"
			 value="com/verticon/rfid/MOVEMENT"/>
     </Provides>

     <ConfigurableProperty field="topics" name="event.topics" />

     <callback final="VALID" initial="INVALID" method="starting"/>
     <callback final="INVALID" initial="VALID" method="stopping"/>
 </component>
</iPOJO>

Am I setting up the metadata correctly?

cheers,
John


> 
> -> richard
> 
> John E. Conlon wrote:
> > Have been using ServiceBinder to wrap components while experimenting
> > with the Configuration Admin service implementation that is in the
> > ApacheDS sandbox. ServiceBinder is cool but I am having problems
> > integrating its behavior with that of Configuration Admin. 
> >
> > When the configurations change in a backing store, the Configuration
> > Admin service will send those configuration changes to implementations
> > of ManagedService and ManagedServiceFactory.
> >
> > My ServiceBinder component implements ManagedService so it receives
> > updates through the 
> > updated(Dictionary configurationAdminProperties) method.
> >
> > Thought that I could just update the ServiceBinders InstanceReference
> > properties to propagate these changes to the serviceRegistry, but
> > changing the InstanceReference properties has no effect on the
> > properties associated with my registered service. (With a handle to
> > ServiceRegistration I could set them there.)
> >
> > How can I propagate these properties to the service registry from within
> > a serviceBinder component? 
> >
> > Does the Declarative Services already do this kind of integration with
> > Configuration Admin out of the box?
> >
> > thanks any ideas,
> > John
> >
> >
> >   
> 


Mime
View raw message