Have you tries something like: karaf@root> config:edit net.iocanel.someservice-instance1 karaf@root> config:propset somekey somevalue karaf@root> config>propset service.factoryPid net.iocanel.someservice karaf@root> config:update
On Fri, Jan 21, 2011 at 18:00, Ioannis Canellos <[email protected]> wrote: > Hi all, > > I am using a managed service factory (via springdm) to create instances of a > service: > > <osgix:managed-service-factory factory-pid="net.iocanel.someservice" > update-strategy="container-managed" auto-export="all-classes"> > <bean class="net.iocanel.SomeService"/> > </osgix:managed-service-factory> > > From the karaf shell I use the config command to create a new instance of > that service say "instance1": > > karaf@root> config:edit net.iocanel.someservice-instance1 > karaf@root> config:propset somekey somevalue > karaf@root> config:update > > As a result a new instance of the service is created and the configuration > is persisted in the file etc/net.iocanel.someservice-instance1.cfg > The problem is that its assigned a random service.pid of the > form net.iocanel.someservice.b95c9421-77e8-474d-8083-7665a0cfcedf and when I > try to update the configuration > > karaf@root> config:edit net.iocanel.someservice-instance1 > > It doesn't work. Instead I have to use the assigned pid (which requires me > to perform a config:list and then use correlate): > > karaf@root> > config:edit net.iocanel.someservice.b95c9421-77e8-474d-8083-7665a0cfcedf > > > I might miss some piece of information here. Has anyone else had encountered > similar issues? > > > -- > *Ioannis Canellos* > http://iocanel.blogspot.com > Integration Engineer @ Upstream S.A. <http://www.upstreamsystems.com> > -- Cheers, Guillaume Nodet ------------------------ Blog: http://gnodet.blogspot.com/ ------------------------ Open Source SOA http://fusesource.com
