Hibernate with MySQL - a beginners guide

Ian P. Christian's personal blog

Quicksearch

Recent Entries

Calendar

Back July '09
Mon Tue Wed Thu Fri Sat Sun
    1 2 3 4 5
6 7 8 9 10 11 12
13 14 15 16 17 18 19
20 21 22 23 24 25 26
27 28 29 30 31    

Blog Administration


Trackbacks

Hibernate with MySQL - a beginners guide - part 2
This post is a follow on from my previous post Hibernate with MySQL - a beginners guide - part 1. Having followed part 1, you should have a simple java application that prints 'ok', an ant build script, and downloaded hibernate and the MySQL connecto
Weblog: Ian P. Christian's personal blog
Tracked: Aug 01, 18:17
Hibernate with MySQL - a beginners guide - part 3
In part 1 and part 2 I showed how to get up and running with hibernate. This part continues from where we left off. I have packaged up all the files form part 2, including all required jars, and the build script. The file is 4.5meg, and is down
Weblog: Ian P. Christian's personal blog
Tracked: Aug 01, 22:14

Comments
Display comments as (Linear | Threaded)





Should the classname not read uk.co.pookey.hibernate.HibernateUtil or am I mistaken?
#1 Dan McDaid on 2008-08-24 17:24 (Reply)
You have an error in your ant script around line 35. You need to change the following from

classname="events.EventManager"

to

classname="uk.co.pookey.hibernate.HibernateUtil"

Thanks anyway, like what you have done so far ;-)

Cheers
#2 anonymous coward on 2008-12-01 13:39 (Reply)
Hello,

Can anyone let me know what should be the commands to compile and run this to get the above mentioned output?

am using
$>ant compile
thats giving BUILD SUCCESSFUL but what to get rest of the output?

Please help. Thanks!
#2.1 Ams on 2009-02-01 13:52 (Reply)
Use $> ant run
The "run" target will automatically call the "compile" target
#2.1.1 Miha on 2009-02-23 18:38 (Reply)
Thanks for this easy-to-follow (considering the alternatives) tutorial. Had a few problems with my java install but nothing a troubleshoot didn't fix.

Thanks
#2.1.1.1 John Uy (Homepage) on 2009-03-26 00:00 (Reply)
Buildfile: build.xml

clean:
[delete] Deleting directory C:\a_projects\samples\java\samples\joe\hibernate\bin
[mkdir] Created dir: C:\a_projects\samples\java\samples\joe\hibernate\bin

copy-resources:
[copy] Copying 2 files to C:\a_projects\samples\java\samples\joe\hibernate\bin

compile:
[javac] Compiling 3 source files to C:\a_projects\samples\java\samples\joe\hibernate\bin

run:
[java] Exception in thread "main" java.lang.StackOverflowError
[java] at java.lang.String.intern(Native Method)
[java] at java.lang.Class.searchMethods(Class.java:2618)
[java] at java.lang.Class.getMethod0(Class.java:2642)
[java] at java.lang.Class.getMethod(Class.java:1579)
[java] at org.apache.commons.logging.LogFactory.getContextClassLoader(LogFactory.java:438)
[java] at org.apache.commons.logging.LogFactory$1.run(LogFactory.java:222)
[java] at java.security.AccessController.doPrivileged(Native Method)
[java] at org.apache.commons.logging.LogFactory.getFactory(LogFactory.java:218)

... close to 1,000 lines of this exact same message ...

[java] at org.slf4j.impl.JCLLoggerFactory.getLogger(JCLLoggerFactory.java:69)
[java] at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:161)
[java] at org.apache.commons.logging.impl.SLF4JLogFactory.getInstance(SLF4JLogFactory.java:155)
[java] Java Result: 1
#3 jonas on 2009-06-02 19:06 (Reply)

Add Comment

Enclosing asterisks marks text as bold (*word*), underscore are made via _word_.
Standard emoticons like :-) and ;-) are converted to images.
 
Submitted comments will be subject to moderation before being displayed.