Fifteen Years of Web Browsing

Hey!  It's fifteen years today since Mosaic 1.0 was released!

I watched that globe spin and spin and spin for hours during my first year at university...!

On the Joys of Object-Relational Mapping

My name is Ian Nelson. I'm a recovering SQL addict. It's been four weeks since my last stored procedure.

One of my reasons for leaving my cosy permanent job and entering the scary cut-throat world of freelancing was to get a broader exposure to different tools, technologies and methodologies, while remaining with my feet planted firmly in the .NET universe. So, when I got offered a position in a team who were using Subversion, Monorail, Ext.JS, NUnit, Oracle and NHibernate, I jumped at the opportunity.

Of those technologies, it's definitely NHibernate which has most dramatically changed my perspective on how enterprise solutions can (and should) be developed. For many years now, I've considered deep database (particularly SQL Server) skills to be one of my core proficiencies, and have merrily spent (wasted?) countless man hours writing dreary "plumbing" code, by the way of CRUD stored procedures and repetitive Data Access Layers in order to persist my CLR entities to the RDBMS.

Well, no longer, those days are over. I've seen the light and embraced the wonders of NHibernate. For those who are unfamiliar with it, NHibernate is an Object-Relational Mapper, and is a port of a Java utility, Hibernate. The premise is beautifully simple - by decorating your objects with attributes or, more neatly, by creating XML mapping files, you define the mappings between your .NET domain objects and their persisted representation on the database. Then NHibernate handles all the grunt work of saving your objects to and from the database.

Digging deeper, I discovered that NHibernate has been developed in such a way as to make it easy to embrace best practices in database access techniques. Several years ago I read through Fowler's seminal Patterns of Enterprise Application Architecture, and wondered how I would ever find time to develop solutions which made use of the cunning O-R behavioural patterns he described - Lazy Load, Unit of Work, Identity Map, Query Object, Repository, etc. I utterly failed to pick up on this paragraph on page 171:

"Remember that you don't have to build a full-featured database-mapping layer. It's a complicated beast to build, and there are products available that do this for you."

Products such as, yes, NHibernate. Or Wilson ORM, or more recently, the LINQ to SQL offering introduced by Microsoft in the .NET 3.5 Framework.

I'm glad that I have a solid grounding in SQL, and I still believe that other skills related to RDBMSs are useful in the enterprise (i.e. database design, normalisation and index tuning), but I'm pleased that I can now bring myself to relax, stop worrying, and leave an ORM to take care of generating the repetitive CRUD statements required for persisting my domain objects.

So, what have I been doing with all this "free time" that I now have available to me during a hard day at the code face? Well, I've been trying to create systems which are more robust and well-designed by making a concerted effort to embrace Test-Driven Development (for real, this time!) But that's a good topic for a future post...

A few useful NHibernate / ORM Resources:

Trying Twitter Again

OK then.  Scotts Watermasysk and Hanselman have convinced me to give Twitter another try.

My rationale goes something like this:

  • I often find myself with pithy things to share that are unworthy of a blog post. Currently, either I don't share them at all, or I email/IM then to a select few friends. I figure it would be much better to Twitter them, so that anybody who may be interested can pick up on them in the method of their choosing.
  • My favourite aspect of the Facebook phenomenon is the status update functionality, which is essentially what Twitter is, so I should embrace that. Anybody know how to get my Twitter updates to automatically synch' across to my FB status? Updated: Thanks to Gus Perez for letting me know about TwitterSync - just the job!
  • Since my first tentative foray into Twittering, it has come on leaps and bounds, with the @username protocol for sending replies, hashtags, and a wealth of clients. I'm loving twhirl, and the integration with Google Talk.
  • I can even add yet more task to Remember The Milk by sending a direct Tweet.  How cool is that?

Now all I need is the customary legion of followers... :-)  You'll find my tweets at http://twitter.com//ianfnelson

Not Quite Getting Things Done

I currently have:

  • 118 starred personal emails
  • 8 starred business emails
  • 85 active tasks in RTM
  • 145 unread items in Google Reader
  • 157 starred items in Google Reader

where do I start?

Two Great Blog Posts

A couple of simply wonderful (techie) blog posts appeared in my Google Reader recently:

First Day of Contracting

0822: I think I was a little over-cautious regarding my travel arrangements. I'm supposed to be pitching up at the office at 0930 for my first day, yet here I am already, killing time by having a coffee a few hundred yards away. In my defence, I blame the media, whipping us all into a frenzy with warnings of the worst storm in the winter, and disruption to travel, power, and communications - maybe this is true in the exposed regions of Cornwall, Devon and Wales, but here in Leeds city centre it's just another rainy Monday morning.

In preparation for this brief period of offline downtime, I finally installed Google Gears last night, so that I could read my Google Reader subscriptions offline. It's a very clever bit of technology, but there are some limitations:

  • No Images - lots of my favourite feeds, especially the ones that I'd like to read on a dreary Monday morning (I Can Has Cheezburger, Fail Blog, XKCD) are predominantly hotlinked images, which aren't downloaded by Gears for offline viewing.
  • Non-Full-Text Feeds - I've always found it really annoying when RSS feeds only show the first few sentences of a post, and expect me to navigate to the original site to read the full article, but when you're offline such feeds are almost useless.
  • Posts which comment on an online article without giving a summary - OK, I've probably been guilty of this myself, but it's amazing how many blog entries refer to other online content solely by linking, without giving any summary - e.g. "The Sunday Times has this piece today, under a headline that is eerily similar to the one its sister paper used about me a couple of years ago." Not being able to get online, I have no idea what either linked article refers to.

Other than those minor niggles, it's very slick. Still, I might try to chill instead on the train, and catch up on some iPod action.

0839: Music bought recently - Rockferry, the debut opus by hotly-tipped Welsh 23 year-old Duffy. Brilliant, utterly deserving of the praise that has been heaped on her. Nice and tight, just ten tracks, and so soulful. Also last week I bought the first Billy Bragg album in six years, Mr Love and Justice, which by contrast sounds rather unfocussed and lacking in hooks. Yes, the usual witty and acerbic lyrics are still there, but it's lacking a certain something - tunes, perhaps.

0842: I wish I felt more awake. Ben, our wonderful seven month-old boy, has a rotten cold at present which has really knocked the stuffing out of him, hence none of us got very much sleep last night. In an effort to cheer him up yesterday, we took him to The Deep in Hull (he loves watching the fish). Outside, my eye was caught by the appalling grammar in this advertisement:

"Who's Eye?"  Er, what?

For a few seconds I was really confused, and wondered if it might be some intentionally cunning marketing trickery. I ask you, how many people must have seen those words between the idea's conception and the eventual installation of the sign? Surely one of them must have had the presence of mind to think "hang on guys, this doesn't actually make sense.."

0847: Also on the subject of language, across the street from here I can see a salon which is advertising itself as a Hair Cuttery. I like that! I'm trying to think of other possibilities along a similar vein - perhaps a dentist could be a Teeth Fixery, an accountants could be a Figure Fiddlery, or a butcher could be an Animal Killery?  Then again, perhaps not..

1250: Stupid Subway guy!  I quite clearly said I wanted "everything except onions", so what has he given me on my Italian BMT?  Nothing except onions! Honestly, what suit-wearing type would want a lunchtime sandwich stuffed to the brim with pongy onions?  If I were American I'd take it back and complain.

1645: First day over. That was painless enough!  Actually it was pretty easy compared to my days as an FTE. No phone calls from business types, no helpdesk calls from users, no need to plan my next career move or worrying about office politics. Just sitting and coding, using the skills that God gave me, and earning more cash into the bargain. I should have done this years ago.

1704: At the station, waiting for my train, listening to 1973 by James Blunt.  Yes, I know it's James Blunt, but it's a melancholy song, and I love all melancholy songs. Plus, it reminds me of relaxing in a coffee shop in Bratislava with my wife and son.

1730: Listening to the Andromeda Heights LP by Prefab Sprout. Evidently there was a reason I hadn't obtained a copy of this sooner - not their finest hour, is it?

1807: Walking home from the train station, catching up on some recent albums. Enjoying Challengers by The New Pornographers. Myriad Harbour is great, undoubtedly the best thing I've heard all week! :-)

Not That SSIS..

Hmm, this wasn't quite what I expected to find when searching Amazon for a book on SSIS.

Still, might as well add it to my DVD rental list... ;-)

The Great 'Quake of '08

My favourite piece of media coverage of last night's dramatic tremor (which woke a nation but resulted in just one broken bone):

"A woman in Notting Hill, a wealthy section of London, reported that her radio was bumping up and down on a shelf for several seconds."

http://abcnews.go.com/International/WireStory?id=4351061&page=2

Says it all!

Two Random Thoughts, 26th February 2008

1. I had a routine eye test today, and was told that my eyesight has improved since my last test (10th December 2004).  I didn't realise that was even possible!

2. Driving home this evening, across a low-visibility intersection close to an ambulance station, I heard a siren from my left. I slammed on the brakes then felt rather silly when I realised that the siren had, in fact, been part of a PM piece about trouble in the West Bank. There should be laws against radio broadcasts containing such noises during drivetime...

FriendFeed

logo-b I'm not entirely convinced that this site will take off, but should you want to see (or even subscribe to) a composite feed of my online activities, you can now do so at:

http://friendfeed.com/ianfnelson

I think I'll take this opportunity to de-splice my del.icio.us links from my blog feed (which should come as a relief to those of you who have no interest in the multitude of recruitment agency websites that I've been bookmarking recently!)