Tuesday, August 14, 2007
Tuesday, August 7, 2007
Wednesday, July 11, 2007
Hibernating gPasma
In a nutshell, adding Hibernate to a GWT project consists in:

The stack identified as 'GWT Services' actually uses the GWT and Hibernate APIs in order to persist the objects. GWT is used to traffic the objects between server and GUI (RPC calls) and Hibernate is used to manage DB sessions, threading and ultimately generating the DB specific calls.
This is a very simplified DB model for the application that will be implemented for this first Hibernate attempt:
The idea behind it is that a 'Process Model' contains 'Process Disciplines' that at their turn contain 'Tasks'. There might be many Process Models but they won't share the disciplines. This basically means that if if we want to generate a new Process Model from a previously existing one, we just copy all the Disciplines and Tasks to the new. Any modifications made only affect the new Process Model, leaving the previous untouched.
An Eclipse project using GWT and Hibernate should look similar to this (very ugly) image:

The items marked with an * are files that have to be changed/added when adding Hibernate to the project.
- Adding the Hibernate libraries (jars) to the classpath
- Adding your JDBC driver to the classpath
- Creating Object mappings (.hbm.xml files) between your Beans and DB tables
- Configuring Hibernate to use your DB and mappings (hibernate.cfg.xml)
- Configure Log4J (optional - log4j.properties)
- Creating GWT services that will use Hibernate to access the DB (aService.java, aServiceAsync.java, aServiceImpl.java)

The stack identified as 'GWT Services' actually uses the GWT and Hibernate APIs in order to persist the objects. GWT is used to traffic the objects between server and GUI (RPC calls) and Hibernate is used to manage DB sessions, threading and ultimately generating the DB specific calls.
This is a very simplified DB model for the application that will be implemented for this first Hibernate attempt:
The idea behind it is that a 'Process Model' contains 'Process Disciplines' that at their turn contain 'Tasks'. There might be many Process Models but they won't share the disciplines. This basically means that if if we want to generate a new Process Model from a previously existing one, we just copy all the Disciplines and Tasks to the new. Any modifications made only affect the new Process Model, leaving the previous untouched.An Eclipse project using GWT and Hibernate should look similar to this (very ugly) image:

The items marked with an * are files that have to be changed/added when adding Hibernate to the project.
Tuesday, July 10, 2007
Using TortoiseCVS with eclipse
I find SVN (subversion) a version control system far superior to CVS. In order to try to go around some of it's limitations, I'm using TortoiseCVS.
The default connection method used by eclipse is incompatible with TortoiseCVS.
To be able to use both programs to manage code on the client side, some steps are necessary:
C:\sshKeys\pageant.exe C:\sshKeys\ssh2RSA.ppk
The default connection method used by eclipse is incompatible with TortoiseCVS.
To be able to use both programs to manage code on the client side, some steps are necessary:
- Configure eclipse to use tortoise's SSH client
- Check out a fresh working directory (project)
- Configure Tortoise with ssh-keys so you don't need to give passwords all the time
C:\sshKeys\pageant.exe C:\sshKeys\ssh2RSA.ppk
Subscribe to:
Posts (Atom)


