karaf-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ioannis Canellos <ioca...@gmail.com>
Subject Managed Service Factories
Date Fri, 21 Jan 2011 17:00:33 GMT
Hi all,

I am using a managed service factory (via springdm) to create instances of a

<osgix:managed-service-factory factory-pid="net.iocanel.someservice"
update-strategy="container-managed" auto-export="all-classes">
     <bean class="net.iocanel.SomeService"/>

>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):

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*
Integration Engineer @ Upstream S.A. <http://www.upstreamsystems.com>

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message