Tuesday, March 31, 2009

RTFL - Read the Fucking Logs

Read the fucking logs? Yes, it happened so many times, on so many guys. Something that I always try to avoid.

Say, you hit into a problem, you looked into the log file, you could see a bunch of error messages and stacktrace, you read the first line, you didn't bother to read the second and further.

You tried to change the configurations or something that you thought would make sense but the same (or new) error came out. You spent quite some time on it like an hour or a day.

You asked me / your supervisor to look into it and they found clear error messages or indications somewhere down the error log. You felt sorry, you found yourself stupid to waste so much time, you wished to be in the hall of shame for that day.

If this is a recurring habit of your, can you make "reading logs carefully" as a troubleshooting principle?

Friday, March 20, 2009

Some Particulars like Room Names in Aflexi

This is truly a random post. During the lunch time at Full House (NZX), I talked about red-tape/bureaucracy in corporates that I can't stand, then exchanges of some Oz slangs.

When I got back to the office, I came across a blog titled "101 Guide to going to the Men's toilet in Sydney" in my ex-company's internal blog (we still maintain a good relationship basically).

Here're a number of things I raised and discussed over in a meeting an hour ago with the team:
  1. The developer's roster, tasks and deadlines.
  2. The right ways to use the toilet.
  3. The ashtray pot and your ciggy.
  4. The cups and basin.
  5. The room names.
Items 2 to 4 are small particulars but people neglect or find themselves resistant in conforming to social standards, if that're the right words to use, anyway. The Aflexi devhub in PJ, Taman Megah Emas (which I named it Aflexi Gold a while ago), has quite a number of rooms and 3 toilets. I'm thinking of giving them names (since 2 months ago but things got me stuck), like country's, city's, etc.

How're rooms named in your office?

Thursday, March 5, 2009

404 on Nexus

Was stuck for a few minutes as Sonatype Nexus was reporting 404 while I tried to access a POM file. Expiring the cache (right clicking on the troubled repository) is the fix of it.

Wednesday, March 4, 2009

Working on Branches and the Stable Trunk

I used to work on the trunk because for all the projects I worked on, it's either I was the sole developer or the team ensured that everyone code check-in has passed the local tests. Otherwise, we created (we still) branches for bug fixes, large code for new features, etc.

About 2 months ago, I had a short git session with Kamal and he shared with me the idea of story/branch. And as my team started to grow with more dev guys, I feel the need of encouraging more branching and now this has become a rule. For a project with automated tests defined with CI set up, a stable trunk is guaranteed and this practice can fit very well into it.

We don't use git but Subversion because that's how we started and we are still comfortable with it now (most of the time).

If you have a working copy on trunk, here're some simple steps to switch to a branch (svn switch won't work):

svn cp https://repo/trunk https://repo/branches/module-version-storyname
cd /path/to/trunk/working/copy
svn diff > /tmp/diff
svn co https://repo/branches/module-version-storyname
cd module-version-storyname
patch -p0 < /tmp/diff