users@glassfish.java.net

Re: Glassfish v2.1 Hibernate

From: <glassfish_at_javadesktop.org>
Date: Mon, 06 Oct 2008 17:08:48 PDT

Hello,

I've found that most of the instructions for using hibernate are out of date and incorrect.

I have successfully used hibernate by installing the latest version of hibernate and its dependencies into my EAR file; the only jar I had to add to the glassfish domain lib dir was the JDBC driver so that I could create the data source within the glassfish admin console.

I can't confirm whether this would work with simply a WAR file, but if you're not using an EAR you probably should use Tomcat instead; it's much easier to work with and you need an enterprise application to really gain benefits from Java EE.

Be sure to install the SLF4J adapter to output to jdk14 logging, and the converters that reroute from java commons-logging and log4j into slf4j; this seems to result in the optimal logging setup, because you can configure all the logging from within the glassfish admin console.

Hope that helps.


--
http://www.dobesland.com
[Message sent by forum member 'dobes' (dobes)]
http://forums.java.net/jive/thread.jspa?messageID=303629