-->
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: Error in Eclipse with Hibernate Annotations
PostPosted: Mon Nov 27, 2006 6:41 pm 
Newbie

Joined: Mon Nov 27, 2006 6:28 pm
Posts: 2
Location: Milwaukee, WI
Need help with Hibernate? Read this first:
http://www.hibernate.org/ForumMailingli ... AskForHelp

Hibernate version: 3.1.3

Hibernate Tools version: 3.2.0 Beta 8

Eclipse version: 3.2.1

This is probably a dumb question as I am a new Hibernate user. Hope you can help !

I am using Eclipse and the Hibernate Tools version above and trying to use annotations from the Tools libs. I am using sample code from the Apress book Beginning Hibernate. However, when I try to run this code :

SessionFactory factory = config.configure().buildSessionFactory();

I get this error :


Exception in thread "main" java.lang.IllegalAccessError: tried to access field org.hibernate.cfg.Configuration.xmlHelper from class org.hibernate.cfg.AnnotationConfiguration
at org.hibernate.cfg.AnnotationConfiguration.addInputStream(AnnotationConfiguration.java:655)


Looking at the code in \src, org.hibernate.cfg.AnnotationConfiguration does indeed appear to be attempting this access, which is puzzling.

Any help is appreciated ! Thanks in advance for your attention.

ethan


Top
 Profile  
 
 Post subject:
PostPosted: Mon Nov 27, 2006 7:19 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
the annotations in tools probably don't work with so old a hibernate 3.1.3.

Use versions that work together. read in annotation docs what you need.

today 3.2.0.GA for both projects is the recommended approach.

_________________
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.  [ 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.