-->
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.  [ 5 posts ] 
Author Message
 Post subject: org.hibernate.tool.ant.HibernateToolTask cannot be found Mvn
PostPosted: Mon Jan 10, 2011 12:41 pm 
Newbie

Joined: Mon Jan 10, 2011 11:55 am
Posts: 5
i'm using Eclipse (Helios SR1 build 20100917-0705) and Hibernate (latest plugin from JBoss (v3.4.0?)) and Maven (v2.2.1) when i try to reverse engineer a table i get the following:

taskdef class org.hibernate.tool.ant.HibernateToolTask cannot be found

via the web and other posts (here) i found that "hibernate-tools.jar" contains that class. i found that jar file deep in the bowels of Eclipse (plugins/org.hibernate.eclipse_3.4.0.v....) and in several other places in eclipse. i unjar'd the file and verified the class is indeed within it.

so, now i have "hibernate-tools.jar"...but where to put it (or put a reference to it)?? here's what i've tried thus far:
1) i created a system CLASSPATH and added the jar file. No Go (still got class not found)!
2) i copied it into \java\jdk\lib. No Go!
i *think* i need this on the classpath for Eclipse..not my project that needs to be able to reverse engineer classes.

1) why can't Eclipse "see" this file...it's in the plugins directory (several times)?
2) since Eclipse cannot "see" this file...where can i put it s.t. it's in Eclipses' CLASSPATH?

thanks!


Top
 Profile  
 
 Post subject: Re: org.hibernate.tool.ant.HibernateToolTask cannot be found Mvn
PostPosted: Mon Jan 10, 2011 1:19 pm 
Newbie

Joined: Mon Jan 10, 2011 11:55 am
Posts: 5
when i search for "hibernate-tools.jar" i find it in ....

C:\tools\eclipse\plugins\org.hibernate.eclipse_3.4.0.v20101206-2100-H28-Beta2\lib\tools

since this used to work (2 months ago). i assume i upgraded something i shouldn't have.


Top
 Profile  
 
 Post subject: Re: org.hibernate.tool.ant.HibernateToolTask cannot be found Mvn
PostPosted: Tue Jan 11, 2011 7:48 am 
Newbie

Joined: Mon Jan 10, 2011 11:55 am
Posts: 5
i added "hibernate-tools.jar" to the build path of my project. when i now rerun reverse generate i get the following:

java.lang.IncompatibleClassChangeError: Found class org.hibernate.cfg.Mappings, but interface was expected

from other posts i think this is caused by incompatible versions (Core/Tools/Annotations). http://community.jboss.org/wiki/Hiberna ... lityMatrix


Top
 Profile  
 
 Post subject: Re: org.hibernate.tool.ant.HibernateToolTask cannot be found Mvn
PostPosted: Tue Jan 11, 2011 9:23 am 
Newbie

Joined: Mon Jan 10, 2011 11:55 am
Posts: 5
just trying to solve the problem ("class not found") that was presented to me. :-(

i've given up on getting this to work on Eclipse Helios as there is only Beta level hibernate support. i've downgraded Eclipse to Galileo and installed Hibernate. now i don't get "class not found". when i run the reverse generate ("Run"..."Hibernate Code Generation") i get a nice progress bar, no errors, yet nothing happens (the table specified in my hibernate.reveng.xml doesn't appear anywhere (least not in the directory/package i specified)).


Top
 Profile  
 
 Post subject: Re: org.hibernate.tool.ant.HibernateToolTask cannot be found Mvn
PostPosted: Tue Jan 11, 2011 12:40 pm 
Newbie

Joined: Mon Jan 10, 2011 11:55 am
Posts: 5
well...i got it to work. i can now reverse engineer tables. why? well, as best i can figure the DB Driver connection information (NOT the hibernate configuration) was setup incorrectly. I was making screen shots to show you...

http://www.mobley.com/hibernate

when i noticed - during Editing the Hibernate Config file that during Editing the Database Connection i peeked at "Driver Properties" and noticed that i hadn't hit the "Edit Driver Definition" icon/button. when i looked there at the Properties i noticed that the connection string was wrong (default??). i corrected it to match what i had setup for the Hibernate Config and viola! i'm able to revGen!

thanks for your assistance!

p.s. How did you get the ER Diagram in Eclipse????


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