Here's some information to give you
some hints, some possible things to explore, but I doubt it will help directly.
You don't say what version of equinox,
or VM, you are using, but if it is pre 3.6 M2, I'd suggest you try with
the latest milestone just to see if it works.
I say this because in 3.6 M2, Bug 285505
was fixed which _might_ be indirectly related.
https://bugs.eclipse.org/bugs/show_bug.cgi?id=285505.
Especially if it does solve your problem,
and you need to use a released version, you can employ a work around in
your own code, by
using the threads threads context classloader.
Something like
Thread.currentThread().setContextClassLoader(this.getClass().getClassLoader());
_before_ your code calls (directly or
indirectly) SOAPPartImpl.
(with all the right resets/trys/finallys,
etc.)
But this type of problem is pretty complicated,
and depends on many things (e.g. which JVM you are using, which and how
many versions of "Node" you have on your classpath, how
and where orasaaj.jar gets its version of 'Node'). There's quite a few
things on the internet that describe or address the issue in different
contexts, one such example is
http://www.ibm.com/developerworks/websphere/library/techarticles/0310_searle/searle.html.
But, I think, its fundamentally a DOM
implementation and JVM issue, and OSGi just finds the problem early, before
it gets to a runtime problem?
But, you say it happens while "trying
to build a bundle" so if you mean that literally ... then my advise
won't really help at all (since it is a runtime solution).
In any case, I hope the information
gives you some things to look at, or to frame the question more precisely.
Good luck,
| From:
|
fox-xoEL0lr7YXyakBO8gow8eQ@public.gmane.org
|
| To:
|
"equinox-dev" <equinox-dev-j9T/66MeVpFAfugRpC6u6w@public.gmane.org>
|
| Date:
|
12/02/2009 08:25 PM
|
| Subject:
|
[equinox-dev] java.lang.LinkageError:
loader constraint violation
|
| Sent by:
|
equinox-dev-bounces-j9T/66MeVpFAfugRpC6u6w@public.gmane.org |
Hello all.
I trying to build a bundle,when
deploy into osgi and run,it throw an error:
java.lang.LinkageError: loader constraint
violation: when resolving overridden method "oracle.j2ee.ws.saaj.soap.SOAPPartImpl.appendChild(Lorg/w3c/dom/Node;)Lorg/w3c/dom/Node;"
the class loader (instance of org/eclipse/osgi/internal/baseadaptor/DefaultClassLoader)
of the current class, oracle/j2ee/ws/saaj/soap/SOAPPartImpl, and its superclass
loader (instance of <bootloader>), have different Class objects for
the type org/w3c/dom/Node used in the signature,
the oracle.j2ee.ws.saaj.soap.SOAPPartImpl
is in orasaaj.jar and it is used by parlayX,I found that the orasaaj.jar
and rt.jar both have this class SOAPPartImpl,
To solve this problem ,what do I have
to do,
in addition, it is normal and successful
that the project just run as a application ,
Many Thanks
Fox_______________________________________________
equinox-dev mailing list
equinox-dev-j9T/66MeVpFAfugRpC6u6w@public.gmane.org
https://dev.eclipse.org/mailman/listinfo/equinox-dev