incubator-clerezza-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bertrand Delacretaz <>
Subject Re: activate(ComponentContext context) or activate() ?
Date Tue, 27 Jul 2010 09:48:53 GMT

On Tue, Jul 27, 2010 at 10:25 AM, Henry Story <> wrote:
> On 26 Jul 2010, at 18:43, Bertrand Delacretaz wrote:
>>... See [1], the activate method needs to have one argument, but 3
>> argument types variants are accepted.
> ...I just tried using the method with signature
>    protected void activate(Map properties)
> in the KeygenService implementation at
> but Clerezza no longer calls it. It does get called when I have the ComponentContext

This should work according to the OSGi compendium spec 4.2, 112.5.8,
"Activate Method".

I'm not too familiar with the Felix code that handles this but it
looks like it's [2] which is getting the activate method, and that
should support a single Map parameter in activate(), but only if the
component is using the Declarative Services spec version 1.1.

According to [3] the maven-scr-plugin detects if your component is
using features from the spec version 1.1, maybe you need to force that
using the specVersion plugin config.

A buggy version of the Felix SCR bundle might also cause the problem,
according to the current
version is 1.4.0.

HTH, and I'm interested in finding out why that doesn't work!



View raw message