Wednesday, June 20, 2012

First Thoughts on the New Project

I have been experimenting with STS and Grails 2.0.4 for one week now. The initial idea was to spend two hours a night five nights a week. The first thing I learned is Monday through Thursday spending two hours at something that feels like work is all right. Friday night I didn't feel like it but I thought Sunday night made more sense anyway. Sunday night I didn't feel like it either. So I am not sure if five nights a week is really going to happen.

Quick Hits

  • If you want to use Groovy Eclipse in STS don't install STS in the Program Files directory.
  • STS is easy to move if you need to, just drop the folder somewhere else.
  • H2 has a console and Grails makes it available in the dev environment (grails dev run-app).
  • You can add an environment to the STS menu commands using Run > Run Configurations...

STS Run Configurations dialog box.
  • Pressing Ctrl+Shift+Alt+G brings up a Grails command prompt.
  • When running in dev use  http://localhost:8080/{appname}/dbconsole to get to the console.
  • The default JDBC URL is jdbc:h2:mem:devDb and Password is blank.
H2 Console login page.
I did write a very small amount of code. Small amounts of code is one of the reasons I really enjoy Grails. One domain class, scaffold controller with two additional actions, taggable plugin, one template, six lines added to the show view and the result is some jQuery fun.

Thursday, June 14, 2012

And the Winner is...


The first task I will try and document is setting up a development machine. I have a nice vanilla 64-bit Windows 7 PC with almost nothing installed. Not even a JDK. The first decision I made is to use Grails, current production version, 2.0.4. The second decision was more difficult, which IDE? I haven't worked in Eclipse for quite awhile. I used to have a total Sun fascination including using NetBeans. There is definitely a pun to be made but I'll restrain myself. If Grails support was included in the community edition of IntelliJ IDEA it would receive strong consideration. One of the reasons I chose STS is there are a lot of resources available to help me learn to use the software. This webinar recording got me excited to get going.

Groovy and Grails Applications with the SpringSource Tool Suite

When I went to download STS I noticed the following:

The following pre-requisites must be fulfilled in order to install STS:
  • Operating System: Microsoft Windows XP/Vista/7, Apple Mac OS X, Linux
  • Java Runtime: latest version of JDK 5 or 6 (a JRE will not be enough to use all STS features)
  • Hardware: 500MB free disk space, 2GB memory

Now I have another decision to make. Is there any reason I wouldn't use Java 6? Additional research may be required. I grabbed the STS version that needs a 64-bit JDK so off to find me some Java. Interesting discovery, I noticed the JRE installed on my 64-bit operating system is a 32-bit version. Might as well get rid of that while I am in setup mode. Wow, Oracle just informed me that 3 billion devices run Java. JDK 6 installed. While installing STS 2.9.2 I have another question. Should I let it install their app server? I am used to Grails having a built-in app server. Do I need vFabric tc Server 2.7.0? I am going to skip it and Maven for now.
Perfect timing, it is 11:00pm.

Wednesday, June 13, 2012

Nine Two Eleven

What can you accomplish in ten hours a week? What if you tried to find out? That is my plan. I want to see how long it takes me to launch a new web site working on it from 9:00 - 11:00pm five nights a week. Here is my expected schedule:
  • 9 -5 work to pay the bills
  • 5 - 9 enjoy my family
  • 9 - 11 do something different
It is highly likely I won't actually work at doing something different as often as I plan but I need to start somewhere so that is what I'll start with.

I have been trying to come up with something to work on and so far the favorite idea is a fairly simple web site. Two items will be displayed and one can be voted for to determine the winner each day. The day's winner will be sent out via Twitter and can be viewed on the site. Simple.

Supply List

Data store to hold the items and the votes
Ability to track who voted
Scheduled process to calculate the winner
Some kind of broadcast

I will try and explain the decisions I make when selecting tools to use in the project. So far I am leaning toward being a SpringSource fanboy and developing a Grails application for Cloud Foundry using STS. Follow along and see if I change my mind.