felix-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Reto Bachmann-Gmuer <reto.bachm...@trialox.org>
Subject Re: bundle.update becomes ineffective after loading class via class loader
Date Tue, 25 Jan 2011 20:07:35 GMT
On Tue, Jan 25, 2011 at 8:47 PM, Richard S. Hall <heavy@ungoverned.org>wrote:

> On 1/25/11 14:17, Reto Bachmann-Gmuer wrote:
>
>> Hello
>>
>> When I attempt to load a class with
>> this.getClass.getClassLoader.load("foo.Hello") this prevents future
>> updates
>> of the bundle exporting foo from being effective, services in that package
>> will not be running with the updated class until felix is restarted or
>> packageAdmin.refreshPackages called.
>>
>> Is this a known problem?
>>
>
> This is not a "problem", that's how the spec defines it. If an exported
> package is being used by some bundle, then an update to the exported bundle
> does not take effect until it is refreshed. This allows you to do multiple
> updates without having to refresh dependent bundles multiple times.
>
Interesting. I though the client bundle would keep the old version but that
other bundles would still get the updated version. Also I'm surprised that
an attempt to load an inexisting class makes the bundle "using" the package
(once the attempt to load the class terminated).

Cheers,
Reto

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