Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EclipseLink » Maven NoClassDefFound: org/eclipse/persistence/internal/libraries/asm/ClassVisitor
Maven NoClassDefFound: org/eclipse/persistence/internal/libraries/asm/ClassVisitor [message #990144] Tue, 11 December 2012 07:10 Go to next message
Jad N is currently offline Jad N
Messages: 3
Registered: December 2012
Junior Member
Hi all,
I'm using maven, and I've added the dependencies for org.eclipse.persistence.jpa v2.4.0, but I keep getting the following exception:

java.lang.NoClassDefFoundError: org/eclipse/persistence/internal/libraries/asm/ClassVisitor
at org.eclipse.persistence.internal.jpa.metadata.MetadataProcessor.processEntityMappings(MetadataProcessor.java:494)
at org.eclipse.persistence.internal.jpa.deployment.PersistenceUnitProcessor.processORMetadata(PersistenceUnitProcessor.java:522)
at org.eclipse.persistence.internal.jpa.EntityManagerSetupImpl.predeploy(EntityManagerSetupImpl.java:1337)
at org.eclipse.persistence.internal.jpa.deployment.JPAInitializer.callPredeploy(JPAInitializer.java:98)
at org.eclipse.persistence.jpa.PersistenceProvider.createEntityManagerFactory(PersistenceProvider.java:105)
at javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:78)
at javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:54)
at com.nerati.filterer.controller.data.impl.CoreRepositoryFactory.start(CoreRepositoryFactory.java:53)
at com.nerati.filterer.controller.data.AnEntityTest.setUp(AnEntityTest.java:43)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:45)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:42)
at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:27)
at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:30)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:263)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:68)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:47)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:231)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:60)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:229)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:50)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:222)
at org.junit.runners.ParentRunner.run(ParentRunner.java:300)
at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:50)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
Caused by: java.lang.ClassNotFoundException: org.eclipse.persistence.internal.libraries.asm.ClassVisitor
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
... 33 more

I know that this missing library is in the un-osgified eclipselink package, but I am running in an OSGI environment. Is there a way to get the missing dependency in a bundle?

Thanks,
Jad.
Re: Maven NoClassDefFound: org/eclipse/persistence/internal/libraries/asm/ClassVisitor [message #990304 is a reply to message #990144] Tue, 11 December 2012 18:35 Go to previous messageGo to next message
James Sutherland is currently offline James Sutherland
Messages: 1939
Registered: July 2009
Location: Ottawa, Canada
Senior Member

You need the EclipseLink asm bundle, org.eclipse.persistence.asm_3.3.1.v201206041142.jar

not sure on maven, but you can always download it from Eclipse

http://www.eclipse.org/downloads/download.php?file=/rt/eclipselink/releases/2.4.1/eclipselink-plugins-2.4.1.v20121003-ad44345.zip


James : Wiki : Book : Blog : Twitter
Re: Maven NoClassDefFound: org/eclipse/persistence/internal/libraries/asm/ClassVisitor [message #990310 is a reply to message #990304] Tue, 11 December 2012 18:53 Go to previous messageGo to next message
Jad N is currently offline Jad N
Messages: 3
Registered: December 2012
Junior Member
Yeah, that's what I eventually did, but isn't it a bug that the one on Maven doesn't have it?
Re: Maven NoClassDefFound: org/eclipse/persistence/internal/libraries/asm/ClassVisitor [message #991506 is a reply to message #990310] Wed, 19 December 2012 15:30 Go to previous messageGo to next message
James Sutherland is currently offline James Sutherland
Messages: 1939
Registered: July 2009
Location: Ottawa, Canada
Senior Member

It should definitely be in maven, if it is not, please log a bug.


James : Wiki : Book : Blog : Twitter
Re: Maven NoClassDefFound: org/eclipse/persistence/internal/libraries/asm/ClassVisitor [message #991518 is a reply to message #991506] Wed, 19 December 2012 16:19 Go to previous message
Matt Butler is currently offline Matt Butler
Messages: 3
Registered: March 2012
Location: Ottawa, Ont, Canada
Junior Member

I ran into this as well... Logged bug at https://bugs.eclipse.org/bugs/show_bug.cgi?id=396943
Previous Topic:distinct keyword in batch fetch query
Next Topic:Multitenancy + Tenants hierarchy
Goto Forum:
  


Current Time: Tue Sep 23 08:38:42 GMT 2014

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

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