felix-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Jencks <david_jen...@yahoo.com.INVALID>
Subject Re: how can two versions of same DS Component coexist ?
Date Wed, 20 Aug 2014 20:44:26 GMT
The two components do look pretty similar…. to configure them separately you have to use
the rather recent feature of targetedPIDS.  I suggest reading about them in the R5 enterprise
spec config admin chapter.  There is support for them in Felix DS 1.8.2 although spec support
is upcoming in R6 enterprise spec.  They are not well tested in practice.

You tell config admin a targetedPID when you set up the configuration.  It's going to have
the form <pid>|<bundle-symbolic-name>|<bundle-version>|<location>
where you only use as many bits (left to right) as you need.

So I think for your case you would have


myPid|myBundleName|1.0.0
myPid|myBundleName|2.0.0

If this doesn't actually work with 1.8.2 please let us know and also try trunk.


BTW I don't know what Luna might include but there is a separate eclipse SCR implementation
unrelated to the felix one.  I don't think anyone has tried to update it to any post R5 features.
 I thought it supported R5/ scr 1.2 so I'm a little surprised you got an error: you wouldn't
be able to configure the components separately however.  Maybe the error comes from config
admin???

thanks
david jencks


On Aug 20, 2014, at 11:28 AM, Hawk Osgi <hawkosgi@yahoo.com.INVALID> wrote:

> confirmed. error gone with Felix 4.4.1 and SCR 1.8.2. great !
> 
> 
> but I still couldn't figure out how to configure a service instance differently for each
version. for now, both services are being activated by the same configuration. investigating...
> 
> 
> regards
> 
> 
> 
> Em Quarta-feira, 20 de Agosto de 2014 10:22, Hawk Osgi <hawkosgi@yahoo.com.INVALID>
escreveu:
> 
> 
> 
> Hi,
> thanks for the time...
> I tried with felix 4.4.0 and scr 1.8.0... will try with felix 4.4.1 and scr 1.8.2.  
> 
> Btw, I also tried with equinox Luna and had the same kind of error ( I thought that equinox
was using the same Scr than felix).
> 
> Could you explain me what is the expected behaviour ? How could I differentiate the 2
components PID or FPID, so I can configure them using ConfigAdmin with different properties?

> 
> regards,
> 
> John
> 
> 
> 
> 
> Em Quarta-feira, 20 de Agosto de 2014 1:33, David Jencks <david_jencks@yahoo.com.INVALID>
escreveu:
> 
> 
> 
> What version of felix ds are you using?  This was not supported in early versions  of
the spec but has been for a while.  Certainly the latest release (1.8.2) supports this.  Of
course there might be a bug….
> 
> thanks
> david jencks
> 
> 
> On Aug 19, 2014, at 7:07 PM, Hawk Osgi <hawkosgi@yahoo.com.INVALID> wrote:
> 
>> Hi,
>> 
>> I'm learning OSGi, I know that I can install different versions of same bundle but
can't find anything in spec about component version.
>> 
>> I installed two versions 1.0.0 and 2.0.0 of a same bundle that contains one DS component.

>> 
>> But when I tried to activate them I got a message complaining about the duplicated
names.
>> 
>> 
>> there are a way tohave two versions of same component activated?
>> 
>> thanks
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> For additional commands, e-mail: users-help@felix.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org


Mime
View raw message