-->
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.  [ 2 posts ] 
Author Message
 Post subject: Hibernate exception
PostPosted: Wed Jun 09, 2010 11:15 pm 
Newbie

Joined: Tue Apr 13, 2010 12:35 am
Posts: 4
Jun 9, 2010 8:12:17 PM org.hibernate.cfg.Environment <clinit>
INFO: Hibernate 3.5.2-Final
Exception in thread "main" java.lang.ExceptionInInitializerError
at org.hibernate.cfg.Configuration.reset(Configuration.java:249)
at org.hibernate.cfg.Configuration.<init>(Configuration.java:216)
at org.hibernate.cfg.Configuration.<init>(Configuration.java:220)
at Hib.Persist.main(Persist.java:20)
Caused by: java.lang.NullPointerException
at org.hibernate.util.ConfigHelper.getResourceAsStream(ConfigHelper.java:167)
at org.hibernate.cfg.Environment.<clinit>(Environment.java:585)
... 4 more



Hi I am getting the following exception at:
SessionFactory sessionfactory =new Configuration().configure().buildSessionFactory();

Can anyone please help me with this. I am a newbie to hibernate. I have included the hibernate jars in the classpath. Using Ant to include jars in the classpath.


Top
 Profile  
 
 Post subject: Re: Hibernate exception
PostPosted: Wed Jun 09, 2010 11:59 pm 
Newbie

Joined: Tue Apr 13, 2010 12:35 am
Posts: 4
Exception in thread "main" java.lang.ExceptionInInitializerError
at Hib.Persist.main(Persist.java:23)
Caused by: java.lang.NullPointerException
at org.slf4j.LoggerFactory.singleImplementationSanityCheck(LoggerFactory.java:192)
at org.slf4j.LoggerFactory.performInitialization(LoggerFactory.java:113)
at org.slf4j.LoggerFactory.getILoggerFactory(LoggerFactory.java:269)
at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:242)
at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:255)
at org.hibernate.cfg.Configuration.<clinit>(Configuration.java:152)
... 1 more


Now after changing the jars i am getting the above exception

The jars currently used are :
antlr-2.7.6.jar
hibernate3.jar
dom4j-1.6.1.jar
commons-collections-3.1.jar
javassist-3.9.0.GA.jar
jta-1.1.jar
mysql-connector-java-5.1.10-bin.jar
slf4j-api-1.5.8.jar
slf4j-nop-1.5.8.jar


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 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.