SDSU Emerging Technology
Fall Semester, 2004
Hibernate & Glorp Install
Previous     Lecture Notes Index     Next     
© 2004, All Rights Reserved, SDSU & Roger Whitney
San Diego State University -- This page last updated 16-Nov-04

CS 683 Emerging Technologies Fall Semester, 2004 Doc 28 Hibernate & Glorp Install

Contents

Installing Hibernate

Glorp

Copyright ©, All rights reserved. 2004 SDSU & Roger Whitney, 5500 Campanile Drive, San Diego, CA 92182-7700 USA. OpenContent ( http://www.opencontent.org/opl.shtml) license defines the copyright on this document

Installing Hibernate

Download Page: http://www.hibernate.org/6.html

Click on the Download from SourceForge link on that page

Download hibernate-2.1.6 and hibernate-extensions-2.1.2

Uncompress the files, no compilation is needed

To run Hibernate you need a

Database

You can use any database you wish

Free databases:

JDBC Drivers

MySQL http://dev.mysql.com/downloads/connector/j/3.0.html

MySQL Connector/J

PostgreSQL http://jdbc.postgresql.org/

Setting Your Classpath

The following jar files need to be in your classpath

Optional jar files

The following files need to be edited and placed in a directory that is in your classpath

Running Hibernate

It is a bit difficult to run Hibernate by hand due to the jar files

Ant

For those that know Ant for an example see

Eclipse

No plugins are needed to run Hibernate programs

Useful Free Eclipse plugins

Problem with Properties Files

On my machine not being loaded

public class Main {
   public static void main(String[] args) throws Exception {
      loadProperties();
      etc.
   }
   
   public static void loadProperties() throws IOException {
      Properties all = new Properties(System.getProperties());
      all.load(propertyStream("hibernate.properties"));
      all.load(propertyStream("log4j.properties"));
      System.setProperties(all);
   }

Glorp

Latest Version

Go to the CINCOM public repository, load in this order:

Preview version

The VisualWorks installation contains a earlier version

Load in the following order:

PostgreSQL connection is already in VW image

MySQL connection is available from CINCOM store, but not highly reliable

Previous     visitors since 16-Nov-04     Next