-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 
Author Message
 Post subject: hibernate-tools.jar
PostPosted: Wed May 21, 2008 3:06 pm 
Beginner
Beginner

Joined: Thu Apr 17, 2008 2:03 pm
Posts: 26
Hi

I want to know what are all the jars needed by hibernate-tools.jar.

I am trying to implement the reverse engineering and added the following jars to the class path:

ant-1.6.5, antrl-2.76, asm, asm-attrs, cglib-2.1.3, commons-collections-2.1.1, commons-logging-1.0.4, dom4j-1.6.1, ehcache-1.2.3, hibernate-annotationsm hibernate-tools, hibernate3, jdbc2_0-stdext and jta jars

But I still get some class linkage problems during the compile time on the following which will result in NoClassDefFoundErrrors when I use the wizard to generate the pojos and hbms at runtime.

I am using Netbeans.

[verifyclasslinkage] Warning: net.sf.cglib.transform.hook.AbstractPreProcessor cannot access
org.codehaus.aspectwerkz.hook.ClassPreProcessor

[verifyclasslinkage] Warning: net.sf.cglib.transform.hook.AsmClassLoaderPreProcessor cannot
access org.codehaus.aspectwerkz.hook.ClassLoaderPreProcessor

[verifyclasslinkage] Warning: net.sf.cglib.transform.hook.AsmClassLoaderPreProcessor cannot
access org.codehaus.aspectwerkz.hook.ClassLoaderPatcher

[verifyclasslinkage] Warning: org.dom4j.datatype.DatatypeAttribute cannot access org.relaxng.datatype.DatatypeException

[verifyclasslinkage] Warning: org.dom4j.datatype.DatatypeAttribute cannot access com.sun.msv.datatype.DatabindableDatatype

And the exception is

java.lang.NoClassDefFoundError: org/dom4j/DocumentException
at org.netbeans.modules.hibernate.wizards.HibernateRevengWizard.generateFiles(HibernateRevengWizard.java:322)
at org.netbeans.modules.hibernate.wizards.HibernateRevengWizard.instantiate(HibernateRevengWizard.java:251)
at org.openide.loaders.TemplateWizard$InstantiatingIteratorBridge.instantiate(TemplateWizard.java:1025)
at org.openide.loaders.TemplateWizard.handleInstantiate(TemplateWizard.java:595)
at org.openide.loaders.TemplateWizard.instantiateNewObjects(TemplateWizard.java:416)
at org.openide.loaders.TemplateWizardIterImpl.instantiate(TemplateWizardIterImpl.java:248)
at org.openide.loaders.TemplateWizardIteratorWrapper.instantiate(TemplateWizardIteratorWrapper.java:161)
at org.openide.WizardDescriptor.callInstantiateOpen(WizardDescriptor.java:1387)
at org.openide.WizardDescriptor.callInstantiate(WizardDescriptor.java:1341)
at org.openide.WizardDescriptor.access$1600(WizardDescriptor.java:119)
at org.openide.WizardDescriptor$Listener$2$1.run(WizardDescriptor.java:1908)
at org.openide.WizardDescriptor$Listener$2.run(WizardDescriptor.java:1957)
at org.openide.WizardDescriptor.lazyValidate(WizardDescriptor.java:1316)
at org.openide.WizardDescriptor.access$1200(WizardDescriptor.java:119)
at org.openide.WizardDescriptor$Listener.actionPerformed(WizardDescriptor.java:1964)
Caused: java.lang.reflect.InvocationTargetException
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:585)
at org.openide.util.WeakListenerImpl$ProxyListener.invoke(WeakListenerImpl.java:449)
Caused: java.lang.reflect.UndeclaredThrowableException
at $Proxy17.actionPerformed(Unknown Source)
at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1849)
at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2169)
at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)


Please help me.

Thanks, G


Top
 Profile  
 
 Post subject:
PostPosted: Thu May 22, 2008 2:48 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
I have no idea what netbeans is doing but the exception is common if you have multiple conflicting classloaders. Ask the ones that did the netbeans work...

_________________
Max
Don't forget to rate


Top
 Profile  
 
 Post subject:
PostPosted: Thu May 22, 2008 3:38 am 
Beginner
Beginner

Joined: Thu Apr 17, 2008 2:03 pm
Posts: 26
Can you at least confirm about the jars. Do I need to add any other jars ?
Or the ones I have are enough ?


Top
 Profile  
 
 Post subject:
PostPosted: Thu May 22, 2008 7:11 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
It all depends what you need.

the minimal set is hibernate3.2, dom4j, log4j, hibernate-tools.jar, cglib.

Eerything else is "add-on", e.g. annotations is only needed if you use annotations, ant only if you use ant, jdbc/jta/ehcace etc. only if you actually need to create a sessionfactory you need ehcache, jdbc etc.

_________________
Max
Don't forget to rate


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.