Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EclipseLink » BundleException in org.eclipse.persistence.jpa.osgi.Activator.start()
BundleException in org.eclipse.persistence.jpa.osgi.Activator.start() [message #825857] Wed, 21 March 2012 06:46 Go to next message
Christian Eugster is currently offline Christian Eugster
Messages: 134
Registered: July 2009
Location: St. Gallen Switzerland
Senior Member
Hi,

I am trying to develop an application with eclipselink (2.3.2) as middleware between the app and the database (local_resource). I added the eclipselink jars to the target environment.

I added three plugins to the product configuration:
plugin startlevel autostart
org.eclipse.core.runtime 0 true
org.eclipse.equinox.common 2 true
org.eclipse.equinox.ds 4 true

When I start my app I get an org.osgi.framework.BundleException (see following stacktrace). What am I doing wrong?

Thanks!

Christian Eugster

!SESSION 2012-03-21 11:28:11.226 -----------------------------------------------
eclipse.buildId=unknown
java.version=1.6.0_31
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=de_CH
Framework arguments: -product ch.eugster.herakles.archive.app.product
Command-line arguments: -product ch.eugster.herakles.archive.app.product -data U:\Incubator Projekte\Herakles\Workspace/../runtime-ch.eugster.herakles.archive.app.product -dev file:U:/Incubator Projekte/Herakles/Workspace/.metadata/.plugins/org.eclipse.pde.core/ch.eugster.herakles.archive.app.product/dev.properties -os win32 -ws win32 -arch x86 -consoleLog -console

!ENTRY org.eclipse.persistence.jpa.osgi 4 0 2012-03-21 11:28:31.595
!MESSAGE FrameworkEvent ERROR
!STACK 0
org.osgi.framework.BundleException: Exception in org.eclipse.persistence.jpa.osgi.Activator.start() of bundle org.eclipse.persistence.jpa.osgi.
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:734)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:683)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.resume(AbstractBundle.java:390)
at org.eclipse.osgi.framework.internal.core.Framework.resumeBundle(Framework.java:1177)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:559)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:544)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(StartLevelManager.java:457)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStartLevel(StartLevelManager.java:243)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:438)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:1)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340)
Caused by: java.lang.LinkageError: loader constraint violation: loader (instance of org/eclipse/osgi/internal/baseadaptor/DefaultClassLoader) previously initiated loading for a different type with name "javax/persistence/EntityManagerFactory"
at org.eclipse.persistence.jpa.osgi.Activator.registerEMFService(Activator.java:153)
at org.eclipse.persistence.jpa.osgi.Activator.registerEMFServices(Activator.java:143)
at org.eclipse.persistence.jpa.osgi.Activator.registerBundle(Activator.java:125)
at org.eclipse.persistence.jpa.osgi.Activator.registerBundleListener(Activator.java:107)
at org.eclipse.persistence.jpa.osgi.Activator.start(Activator.java:96)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl$1.run(BundleContextImpl.java:711)
at java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:702)
... 12 more
Root exception:
java.lang.LinkageError: loader constraint violation: loader (instance of org/eclipse/osgi/internal/baseadaptor/DefaultClassLoader) previously initiated loading for a different type with name "javax/persistence/EntityManagerFactory"
at org.eclipse.persistence.jpa.osgi.Activator.registerEMFService(Activator.java:153)
at org.eclipse.persistence.jpa.osgi.Activator.registerEMFServices(Activator.java:143)
at org.eclipse.persistence.jpa.osgi.Activator.registerBundle(Activator.java:125)
at org.eclipse.persistence.jpa.osgi.Activator.registerBundleListener(Activator.java:107)
at org.eclipse.persistence.jpa.osgi.Activator.start(Activator.java:96)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl$1.run(BundleContextImpl.java:711)
at java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:702)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:683)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.resume(AbstractBundle.java:390)
at org.eclipse.osgi.framework.internal.core.Framework.resumeBundle(Framework.java:1177)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:559)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:544)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(StartLevelManager.java:457)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStartLevel(StartLevelManager.java:243)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:438)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:1)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340)

Re: BundleException in org.eclipse.persistence.jpa.osgi.Activator.start() [message #829643 is a reply to message #825857] Mon, 26 March 2012 11:36 Go to previous message
James Sutherland is currently offline James Sutherland
Messages: 1939
Registered: July 2009
Location: Ottawa, Canada
Senior Member

See, http://wiki.eclipse.org/EclipseLink/Examples/OSGi

or the Eclipse Gemini project


James : Wiki : Book : Blog : Twitter
Previous Topic:PLSQLStoredProcedureCall Fail to convert to internal representation
Next Topic:deadlock in a LAZY fetch
Goto Forum:
  


Current Time: Tue Jul 29 13:15:10 EDT 2014

Powered by FUDForum. Page generated in 0.05421 seconds