On 12/4/09 10:06, Alan Keane wrote:
Hi Tom,
Thanks for the reply.. makes sense
I was just a bit confused by the statement -/* *'if an exported package/ /of the bundle it references has been updated or removed'/ by refreshPackages() - along with some differences I have noticed between felix and equinox.

Feel free to bring the differences to our attention, we love to debate these issues. :-)

-> richard

Thanks,
Alan

------------------------------------------------------------------------
*From:* [email protected] [mailto:[email protected]] *On Behalf Of *Thomas Watson
*Sent:* 04 December 2009 13:16
*To:* OSGi Developer Mail List
*Subject:* Re: [osgi-dev] RequiredBundle clarification - PackageAdmin spec

The RequiredBundle#getRequiringBundles() is only intended to return the bundles wired through Require-Bundle constraints. A RequiredBundle object is removal pending as soon as the bundle content it represents has been updated or uninstalled. The same rule for removal pending applies to ExportedPackage objects. As soon as the bundle content which exports the package has been updated or uninstalled then the ExportedPackage becomes stale. This is related to the class loader which loads the bundle content. If this class loader becomes marked for removal because of an update or uninstall then all exported packages available for load from that bundle class loader must become stale as well as the RequiredBundle object.

Hope that helps.

Tom



Inactive hide details for "Alan Keane" ---12/04/2009 04:09:26 AM---Hi, Apologies if this is clearly stated somewhere but I coul"Alan Keane" ---12/04/2009 04:09:26 AM---Hi, Apologies if this is clearly stated somewhere but I couldn't find an explicit statement in the spec..


From:   
"Alan Keane" <[email protected]>

To:     
<[email protected]>

Date:   
12/04/2009 04:09 AM

Subject:        
[osgi-dev] RequiredBundle clarification - PackageAdmin spec

------------------------------------------------------------------------



Hi,

Apologies if this is clearly stated somewhere but I couldn't find an explicit statement in the spec.. I just want to clarify something in relation to the RequiredBundle#getRequiringBundles() method. Should this method return all bundles that

are currently wired to the underlying bundle as a result of both Require-Bundle and explicit Import-Package statements?

>From the spec:
"The information about a required bundle provided by this object may
change. A RequiredBundle object becomes stale if an exported package of
the bundle it references has been updated or removed as a result of calling PackageAdmin.refreshPackages()). If this object becomes stale, its getSymbolicName()
and getVersion() methods continue to return their original values,
isRemovalPending() returns true, and getBundle() and
getRequiringBundles() return null."

To me, this implies that wiring as a result of explicit Import-Package statements should also be considered. If not, then should the RequiredBundle object only become stale when the bundle it represents no longer exports any packages..

As long as it continues to export 1+ packages then any bundle previously wired as a result of Require-Bundle would remain a valid requiring bundle.

Thanks,
Alan _______________________________________________
OSGi Developer Mail List
[email protected]
https://mail.osgi.org/mailman/listinfo/osgi-dev


_______________________________________________
OSGi Developer Mail List
[email protected]
https://mail.osgi.org/mailman/listinfo/osgi-dev
_______________________________________________
OSGi Developer Mail List
[email protected]
https://mail.osgi.org/mailman/listinfo/osgi-dev

Reply via email to