Now setting up my development environment on Linux (Ubuntu on an Oracle Virtualbox) for use with the ‘Agile Java Development with Spring, Hibernate and Eclipse’ book.

 

So far, have set up the Linux boot with:-

 

Java – Due to issues with Oracle and Linux had to go with OpenJDK and OpenJRE 6.

Found that there’s a handy way of installing some Linux software, by using command line install command rather than hunting around via a browser. Full info athttp://openjdk.java.net/install/

 

Ant – Installed Ant version 1.8.2. Setup the environment variable $ANT_HOME in my .bashrc file.

 

JUnit – Installed JUnit 4.10. Setup the environment variable $JUNIT_HOME in my .bashrc file.

 

HSQLDB – Downloaded this, version 2.2.8. Copied the hsqldb.jar file to the lib directory of the timex project from the book. Started the HSQLDB server using the ant command: ant -f timexhsqldb.xml starthsql and it worked fine. Then created the database tables, test data etc via the ant command: ant -f timexhsqldb.xml execddl. All worked fine.

To check the data looked ok I ran the HSQLDB Manager – via ant command ant -f timexhsqldb.xml hsqldm. This worked ok and the data was there.

 

 

Hibernate – Installed Hibernate 3.5.6.

 

Then ran the test suite using the ant command ant rebuild test. This ran ok and showed everything so far was setup/working ok.

Apache Tomcat – Installed version 7.0.25. Set environment variable CATALINA_HOME to the install directory. Set deploy.dir in local.properties to the correct path for the webapp deployment. Ran the ant command ant deploy to the deploy the WAR file to the webapp directory as set in the deploy.dir setting. Initially had permisson problems due to the settings of the destination directory, but after some changes to the permissions this worked fine. (Note: This site was useful for this step http://linux-sxs.org/internet_serving/c140.html#INSTALL)

Next install is the Spring Framework…