Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Plugin Development Environment (PDE) » Dependencies leaking outside a bundle
Dependencies leaking outside a bundle [message #65584] Thu, 25 June 2009 06:42
bank kus is currently offline bank kusFriend
Messages: 13
Registered: July 2009
Junior Member
==========
BACKGROUND:
==========
Consider the following example:
Bundle A
|_______ export package B[1.0.0]
|_______ import package M[3.0.0, 4.0.0)

The catch here being an interface ISomeInterface belonging to package M
"leaks out of package B". Now this is a term I just coined for want of a
better term.

ISomeInterface could leak out of package B if its part of the method
signature or public field of any public class/interface in package B.

What I noticed is if Bundle A upgrades from M[3.0.0, 4.0.0) to M[4.0.0,
5.0.0) then it must also upgrade its own exported package B to [3.0.0]. If
it did not do so then another package/bundle using it can lose binary
compatibility since it could be using M[3.0.0, 4.0.0] itself and this will
present a case where a single interface exists within the same classloader
at two different versions. Based on a test run JVM throws
"IncompatibleClassChangeError".

==========
QUESTION:
==========
<a> Is the above analysis of backwards compatibility correct?
<b> Is there a way to detect this pattern of error using the PDE toolchain
without actually deploying and getting Java runtime Errors?

Regards
banks
Previous Topic:OSGI Bundle Build failure only when exporting for deployment
Next Topic:Dependencies leaking outside a bundle
Goto Forum:
  


Current Time: Mon Dec 30 16:53:01 GMT 2024

Powered by FUDForum. Page generated in 0.03248 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top