Taking the Java Plunge – release 1.0 reached

Well I made it. It was early in the weekend that the code was working, but its taken a couple more days of struggle to get it so I could put it into production. Learning how to get tomcat to authorize the users is hell to debug when it doesn’t seem to do what the book says it should.

Looking back at what I have done surprises me. It was a simple application (just 5 web pages) but the number of separate technologies that I had to learn (or in some cases perfect) were many. Here is a list (on top of Debian Unstable/Stable)

Well I made it. It was early in the weekend that the code was working, but its taken a couple more days of struggle to get it so I could put it into production. Learning how to get tomcat to authorize the users is hell to debug when it doesn’t seem to do what the book says it should.

Looking back at what I have done surprises me. It was a simple application (just 5 web pages) but the number of separate technologies that I had to learn (or in some cases perfect) were many. Here is a list (on top of Debian Unstable/Stable)

  • download and conversion to debian package of sun sdk
  • set up and configuration of Tomcat
  • complilation of jk_mod from source
  • installation and configuration of jk_mod into Apache2
  • download, installation and use of Eclipse with Web Tools (including debugging)
  • download, installation and use of git (and cogito) scm system
  • Java Programming – with special attention having to be paid to the Collections classes
  • download, installation of Tapestry web framework
  • learning all of the Tapestry concepts (basic, forms with translaors and application state objects in particular)
  • download, installation of iBatis database framework
  • learning the use of iBatis concepts (with complex joins and how they populated Java collection classes)
  • set up of postgres access controls so that code and myself (using psql) could create and then access the database
  • SQL for key transactions, and in particular complex joins in order to extract the family relationships from the database
  • set up of jdbc driver for Postgres and configuration in Tomcat so that could access family tree database
  • set up of a datasource realm in Tomcat and a users database in Postgres to provide access controls to application
  • html encoding
  • css encoding
  • javascript and how to use within the Tapestry framework
  • Povray to create the chandlerfamily logo (not in the timeframe of this project – was done earlier)
  • inkscape to draw graphic items
  • gimp to convert graphic items to gif

Taking the JAVA plunge – into the last mile

After some hard work at getting my ideas together and then some marathon debugging sessions, my application is almost working. It has taken me a lot longer than I envisioned – for two real reasons.

Firstly, for a long time I had an approximate idea of what screens and what workflow I wanted in the application but I was finding it difficult to make it concrete. When I didn’t have a clear picture of what I was aiming at, my development didn’t proceed.

After some hard work at getting my ideas together and then some marathon debugging sessions, my application is almost working. It has taken me a lot longer than I envisioned – for two real reasons.

Firstly, for a long time I had an approximate idea of what screens and what workflow I wanted in the application but I was finding it difficult to make it concrete. When I didn’t have a clear picture of what I was aiming at, my development didn’t proceed.

In the end, I found that to draw out the screen layouts and then merge them onto a single page as the best thing to do. I then printed them out and annotated the copies with the actions and how they were going to control variables across the application. This picture shows the layout that I drew (which is close to what I will end up with).

Unfortunately the picture that I had placed here in this blog entry has been lost

I found Inkscape www.inkscape.org under both Windows and Linux as a really good tool to do this. I first drew each page as a separate drawing, and then used the import tool to pull them all together in a single drawing.

Unfortunately, I found Inkscape cumbersome for drawing arrows to represent the transitions between the pages. Initially I just used marks on the printed copies, but these got difficult to see with so many scribbles, so in the end I used KIVIO under kde to draw single simple boxes for the pages and coloured arrows for the flows between them.

update I now use DIA for this, and export the result as an SVG which I can then size and export as a PNG image using Inkscape

The second reason for lack of progress was trying to be too clever with not creating a session objects to store persistance data in. I was trying to carry the data between pages, and getting screwed up when the page was being recreated without access to the information I wanted. As soon as I created a few Tapesty “Application State Objects” for my session, and just got standard forms to load data to and from these objects everything became a lot simpler.

Now just trying to complete the javascript for a dynamic piece on my Edit page, looking at using CSS for control of the formats on all pages (and using the same to provide mouse hover tool tips) and I will be moving on to production deployment.

I’ll report on that soon.