Hello Karaf Team,
i don't know if it is the correct mailing list, because its just possibly
related to karaf specific implementation.
I try to configure multiple services which are created by a component factory
(newInstance). But i don't find a way how i can give a unique pid to a created
s
Hi Matthias,
What about creating a new service instance with a ManagedServiceFactories ?
If you use SCR, it's pretty easy. It's the way it's implemented in
Decanter for instance.
For instance, a new TailerListenerAdapter service will be registered for
each etc/org.apache.karaf.decanter.collector
Hi,
If you are using Component Factories then you are not also using Managed
Service Factories, the two are simply not possible to use together.
A component factory lets you supply custom configuration to programmatically
create multiple instances of a component. These are combined with any st
By the way, you also have a "core" example here:
https://github.com/apache/karaf/tree/master/examples/karaf-config-example/karaf-config-example-managed-factory
and the equivalent with SCR:
https://github.com/apache/karaf/tree/master/examples/karaf-config-example/karaf-config-example-scr
Regards
: ComponentFactory
By the way, you also have a "core" example here:
https://github.com/apache/karaf/tree/master/examples/karaf-config-example/karaf-config-example-managed-factory
and the equivalent with SCR:
https://github.com/apache/karaf/tree/master/examples/karaf-config-example/karaf-conf
I’m not sure I understand what you are trying to do, since you keep mentioning
ManagedServiceFactory but I don’t see any such in your code, and they don’t
play well with DS. I think you want to have a factory component (i.e.
ComponentFactory) where the newInstances are registered with DS as
Is there a way to list available factoryPids (before creating a
> configuration)?
>
> best regards,
> Matthias
>
>
>
>
>
> *Von:* Jean-Baptiste Onofré
> *Gesendet:* Montag, 25. März 2019 15:
raf.apache.org
Betreff: Re: AW: ComponentFactory
Hi Matthias,
as always, happy to help ;)
config:list command/service is able to list the configuration (including
the factories).
Regards
JB
On 25/03/2019 16:07, Matthias Leinweber wrote:
> Thank you very much.
>
> Thanks for the explanation, Ti
list) are present. But the factory is not.
>
> I think i am still missing a basic concept?
>
> regards,
> Matthias
>
>
> *Von:* Jean-Baptiste Onofré
> *Gesendet:* Montag, 25. März 2019 16:57:59
e...
best regards,
Matthias
Von: Jean-Baptiste Onofré
Gesendet: Montag, 25. März 2019 18:36:17
An: user@karaf.apache.org
Betreff: Re: AW: AW: ComponentFactory
Hi,
you should have a config with FactoryPid as property right ?
For instance, when I do config:list, I c
>
> *Von:* Jean-Baptiste Onofré
> *Gesendet:* Montag, 25. März 2019 18:36:17
> *An:* user@karaf.apache.org
> *Betreff:* Re: AW: AW: ComponentFactory
>
> Hi,
>
> you should have a config with Fa
@karaf.apache.org
Subject: Re: AW: AW: AW: ComponentFactory
Not sure I follow you.
What's the issue ?
You have the factory and the configurations for the factory.
Regards
JB
On 25/03/2019 18:54, Matthias Leinweber wrote:
> Yes,
>
>
> but i s
... i can iterate over "my" servicefactories.
From: Matthias Leinweber
Sent: Monday, March 25, 2019 8:00:25 PM
To: user@karaf.apache.org
Subject: Re: AW: AW: AW: ComponentFactory
Mhm OK.
I will try to explain what i want to achieve.
My Plan was
March 25, 2019 8:00:25 PM
> *To:* user@karaf.apache.org
> *Subject:* Re: AW: AW: AW: ComponentFactory
>
> Mhm OK.
>
> I will try to explain what i want to achieve.
>
> My Plan was to create several ManagedserviceFac
est regards,
Matthias
Von: Jean-Baptiste Onofré
Gesendet: Dienstag, 26. März 2019 06:15:26
An: user@karaf.apache.org
Betreff: Re: AW: AW: AW: ComponentFactory
Hi Mathias,
The factoryPid doesn't change: it's com.foo.bar.
The configurationPid is based on
uot;prop3", "foobar");
> cfg.update(testProp);
> }
> }
>
> And now i like to create some services from type A, some from type B and then
> i like to change configurations of existing services.
>
> best regards,
> Matthias
> Von: Jean-Baptist
oin(" ",
componentDescriptionDTO.configurationPid))
.filter(s -> s.startsWith("my.pre.fix"))...
best regards,
Matthias
Von: David Jencks
Gesendet: Dienstag, 26. März 2019 17:01:13
An: user@karaf.apache.org
Betreff: Re: AW: AW: AW: AW: ComponentF
Hey all! Does anyone can help me with this question?
https://stackoverflow.com/questions/52118716/unable-to-deploy-a-karaf-kar-file-containing-a-componentfactory-osgi-declarative
Thanks
p.s. I have tried to send the question directly to here before but seems
that I wasn't properly add
rflow.com/questions/52118716/unable-to-deploy-a-karaf-kar-file-containing-a-componentfactory-osgi-declarative
>
> Thanks
>
> p.s. I have tried to send the question directly to here before but seems
> that I wasn't properly added to the list. Given another try...
>
>
stion?
> >
> https://stackoverflow.com/questions/52118716/unable-to-deploy-a-karaf-kar-file-containing-a-componentfactory-osgi-declarative
> >
> > Thanks
> >
> > p.s. I have tried to send the question directly to here before but seems
> > that I wasn't p
Oh sorry, I missed the cause: the service
org.osgi.service.component.ComponentFactory is not there ;)
Why do you have as a prerequisite ?
I guess that if you install the scr feature before the kar it works fine
right ?
Can you check if you have the ComponentFactory service ?
By the way, why
that if you install the scr feature before the kar it works fine
> right ?
>
> Can you check if you have the ComponentFactory service ?
>
> By the way, why did you define the requirement in your bundle ?
>
> Regards
> JB
>
> On 01/09/2018 18:19, Thiago Moreir
Oh sorry, I missed the cause: the service
> org.osgi.service.component.ComponentFactory is not there ;)
>
> Why do you have as a prerequisite ?
>
> I guess that if you install the scr feature before the kar it works fine
> right ?
>
>
i.service.component.ComponentFactory is not there ;)
> >
> > Why do you have as a prerequisite ?
> >
> > I guess that if you install the scr feature before the kar it works
> fine
> > right ?
> >
> > Can you check if y
Karaf kar file containing
a ComponentFactory OSGi declarative service
I have tried with Karaf 4.2.1 without lucky. My steps:Unzip the bundleStart
with karaf commandBuild the project with mvn clean install
Install the kar fileCopy the kar file
br.com.thiagomoreira.kar-1.0.0-SNAPSHOT.kar to the depl
ançois
>
>
>
> Envoyé depuis mon smartphone Samsung Galaxy.
>
> Message d'origine
> De : "Thiago Moreira (timba)"
> Date : 02/09/2018 16:14 (GMT+04:00)
> À : user@karaf.apache.org
> Objet : Re: Unable to deploy a Karaf kar file containing
ailto:j...@nanthrax.net>
> > <mailto:j...@nanthrax.net <mailto:j...@nanthrax.net>>> wrote:
> >
> > Oh sorry, I missed the cause: the service
> > org.osgi.service.component.ComponentFactory is not there ;)
> >
>
> Thiago Moreira
> > +55 48 99911-6331
> >
> >
> > On Sat, Sep 1, 2018 at 1:28 PM Jean-Baptiste Onofré
> mailto:j...@nanthrax.net>
> > <mailto:j...@nanthrax.net <mailto:j...@nanthrax.net>>> wrote:
> >
> > Oh sorry, I mis
: user@karaf.apache.org <mailto:user@karaf.apache.org>
> Objet : Re: Unable to deploy a Karaf kar file containing a
> ComponentFactory OSGi declarative service
>
>
> I have tried with Karaf 4.2.1 without lucky. My steps:
>
> 1. Unzip the bundle
&
-- Message d'origine
>> De : "Thiago Moreira (timba)"
>> Date : 02/09/2018 16:14 (GMT+04:00)
>> À : user@karaf.apache.org
>> Objet : Re: Unable to deploy a Karaf kar file containing a
>> ComponentFactory OSGi declarative service
>>
&
nce(target = "(component.factory=bot.factory)")
protected ComponentFactory factory;
regards,
François Papon
fpa...@apache.org
Le 02/09/2018 à 19:01, Thiago Moreira (timba) a écrit :
>
> Nice! I already look the example.
>
> Thiago Moreira
> +55 48 99911-6331
>
>
> On
gin instead of the bnd-plugin, it's
> more convenient ;)
>
> Btw, I see that in your BotApplication class you are searching a
> service with a component.factory property = bot.factory but I can't
> see where you are registring this factory
>
> @Reference(target = "(com
;)
>
> Btw, I see that in your BotApplication class you are searching a service
> with a component.factory property = bot.factory but I can't see where you
> are registring this factory
>
> @Reference(target = "(component.factory=bot.factory)")
> protected Comp
Ok,
>>
>> You should use the maven-bundle-plugin instead of the bnd-plugin,
>> it's more convenient ;)
>>
>> Btw, I see that in your BotApplication class you are searching a
>> service with a component.factory property = bot.factory but I
>
gt;>
>>> You should use the maven-bundle-plugin instead of the bnd-plugin,
>>> it's more convenient ;)
>>>
>>> Btw, I see that in your BotApplication class you are searching a
>>> service with a component.factory property = bot.factory b
t;
> >>
> >> Le 02/09/2018 à 19:09, Francois Papon a écrit :
> >>>
> >>> Ok,
> >>>
> >>> You should use the maven-bundle-plugin instead of the bnd-plugin,
> >>> it's more convenient ;)
> >>
>> François Papon
> >> fpa...@apache.org <mailto:fpa...@apache.org>
> <mailto:fpa...@apache.org <mailto:fpa...@apache.org>>
> >>
> >> Le 02/09/2018 à 19:09, Francois Papon a écrit :
> >>>
>
Sorry, I missed it, I see it now :)
>> >>
>> >> @Component(service = Bot.class, factory = "bot.factory")
>> >> public class BotImpl implements Bot {
>> >>
>> >> regards
>> >>
>> >> Fra
Hi Milen,
effective means that it expects a service available in the registry. So,
if ComponentFactory is preset in the registry (you can check with the ls
command), it should work via the feature.
I will provide a fix to Thiago.
Regards
JB
On 03/09/2018 16:40, Milen Dyankov wrote:
> This i
he.org
Le 03/09/2018 à 19:02, Jean-Baptiste Onofré a écrit :
> Hi Milen,
>
> effective means that it expects a service available in the registry. So,
> if ComponentFactory is preset in the registry (you can check with the ls
> command), it should work via the feature.
>
> I will pro
<mailto:fpa...@apache.org <mailto:fpa...@apache.org>>
> >>
> >> Le 02/09/2018 à 19:09, Francois Papon a écrit :
> >>>
> >>> Ok,
> >>>
> >>> You should use the maven-bundle-plug
ommand output.
>
> However it's not binded in the BotApplication by the @Reference.
>
> regards,
>
> François Papon
> fpa...@apache.org
>
> Le 03/09/2018 à 19:02, Jean-Baptiste Onofré a écrit :
> > Hi Milen,
> >
> > effective means that it expects a se
gt; fpa...@apache.org
>>
>> Le 03/09/2018 à 19:02, Jean-Baptiste Onofré a écrit :
>> > Hi Milen,
>> >
>> > effective means that it expects a service available in the registry. So,
>> > if ComponentFactory is preset in the registry (you can check with
Yes, I also tried to install the feature manually (JB tips) outside of
the Kar but it didn't solve.
May be I missed something in Felix for the registring of the component
in the componentFactory.
regards,
François Papon
fpa...@apache.org
Le 04/09/2018 à 15:42, Milen Dyankov a écrit :
>
oblem).
I keep you posted asap.
Regards
JB
On 04/09/2018 13:47, Francois Papon wrote:
> Yes, I also tried to install the feature manually (JB tips) outside of
> the Kar but it didn't solve.
>
> May be I missed something in Felix for the registring of the component
> in the
idn't solve.
> >
> > May be I missed something in Felix for the registring of the component
> > in the componentFactory.
> >
> > regards,
> >
> > François Papon
> > fpa...@apache.org
> >
> > Le 04/09/2018 à 15:42, Milen Dyankov a écrit
his question?
> https://stackoverflow.com/questions/52118716/unable-to-deploy-a-karaf-kar-file-containing-a-componentfactory-osgi-declarative
>
> Thanks
>
> p.s. I have tried to send the question directly to here before but seems
> that I wasn't properly added to the list. Given
>
> https://stackoverflow.com/questions/52118716/unable-to-deploy-a-karaf-kar-file-containing-a-componentfactory-osgi-declarative
> >
> > Thanks
> >
> > p.s. I have tried to send the question directly to here before but seems
> > that I wasn't properly added t
48 matches
Mail list logo