Hibernate Books

All times are UTC - 5 hours [ DST ]



Post new topic Reply to topic  [ 4 posts ] 
Author Message
 Post subject: java.lang.NoClassDefFoundError: org/hibernate/cfg/SettingsFa
PostPosted: Fri May 26, 2006 4:26 am 
Newbie

Joined: Fri May 26, 2006 4:19 am
Posts: 2
Hi all,
I already downloaded hibernate-entitymanager-3.2.0.CR1 and tried to use in J2SE project. I added all jars that are included in zip on my project classpath (hibernate-entitymanager.jar, ejb3-persistence.jar, hibernate-annotations.jar, javassist.jar, jboss-archive-browsing.jar).

However, I got exception when the project was executed:

Exception in thread "main" java.lang.NoClassDefFoundError: org/hibernate/cfg/SettingsFactory
at org.hibernate.ejb.HibernatePersistence.createEntityManagerFactory(HibernatePersistence.java:113)
at javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:37)
at javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:27)

What is missing on project classpath? Should I download also other Hibernate packages? It's as usability issue for me since there is no info which jars are needed.


Top
 Profile  
 
 Post subject:
PostPosted: Fri May 26, 2006 5:43 am 
Pro
Pro

Joined: Mon Jan 24, 2005 5:39 am
Posts: 216
Location: Germany
Hi blaha,

you also need hibernate3.jar and maybe some more jars which are
contained in hibernate core.
See:

http://www.hibernate.org/299.html

under Requirements.

_________________
dont forget to rate !


Top
 Profile  
 
 Post subject:
PostPosted: Fri May 26, 2006 12:22 pm 
Newbie

Joined: Fri May 26, 2006 4:19 am
Posts: 2
Hi steckemetz,
thanks for you quick reply. I was able to run my application with Hibernate. I used Netbeans for developing J2EE applications and it seems that is a liitle bit complicated to setup a right environment for using Hibernate Entitymanager in Netbeans. Therefore, I created new Hibernate library modules that includes all required jars. See:

http://blogs.sun.com/roller/page/pblaha ... r_netbeans

User can simple install this module and then very easy use persistence and other Hibernate stuff in NetBeans 5.5.

Petr


Top
 Profile  
 
 Post subject:
PostPosted: Mon Aug 20, 2007 3:22 pm 
Newbie

Joined: Fri Jul 20, 2007 6:02 pm
Posts: 12
Quote:
java.lang.NoClassDefFoundError: org/hibernate/cfg/SettingsFactory

Check CLASSPATH always


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 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.