Blogs

Unexceptional examples

We’re going to run out of amusing titles for these exception related blog entries sooner or later… Joel wants Ned to rename the functions in his ’exceptions are better’ example. He wants InstallSoftware(), CopyFiles() and MakeRegistryEntries(). Jesse Ezell leapt in with a C# version which includes the rollback functionality that Joel was undoubtedly hinting at. The thing is, although Jesse is defending the use of exceptions, I think his example is making the case for the other side…

Tests and TDD in anger

This week we started to make some changes to the FX code. The existing code made some strange assumptions about some of the edge cases and the resulting display was occasionally inconsistent. We fixed that, and the tests saved us from a couple of embarrassing mistakes. Meanwhile, in my free time, the test driven POP3 server development continues. I now have a working server that can run off of a message store that lives on the file system and can do all the things that a POP3 server is supposed to do.

Exceptions are for exceptional situations

Like drumming up traffic to your site, perhaps? ;) On Monday Joel Spolsky wrote a controversial piece about exceptions; he hates them. Much blog cross linking and local discussion ensued. Today he’s followed that piece up with a piece that basically says ’exceptions can be good and they can be bad, it’s a design tradeoff’. Which, of course, takes all the controversy out of the original posting; strangely I was expecting something like this…

MSDN Reloaded

Wheee. I can throw all of my existing MSDN disks in the disk bucket and I don’t need to keep wondering which is the latest version. They’ve changed my subscription ‘for the better’… Hmm, it seems that now the colours will be used to identify the type of disk (I’m sure that’s how it used to be before they changed the subscription ‘for the better’ last time around) and the major numbers will stay the same when a disk replaces another disk, only the minor number will increment… Sounds sensible… I hope it works.

I've got a brand new combine harvester and I'll give you the key...

The harvesting of the SSL server code took about an hour in all. It was simply a case of shuffling some code around, ripping it out of a project and into the library and then adjusting the original server and the POP3 server to suit. So, I now have a POP3 server on 110 and 995; and Outlook even lets me know that my server certificate is bogus… I guess I need a real message store now…

Harvest Time

I had a bit of spare time today so I finished the POP3 server integration. It went nice and smoothly and I tested the result with telnet and Outlook. During the Outlook testing I noticed the ’this server requires a secure connection (SSL)’ checkbox. I hadn’t been aware that there was a standard port (995) for accessing a POP3 server over SSL. My server currently only supports port 110 for unencrypted transport but I’ve got code that can turn my server into an SSL enabled server… Looks like it’s time to harvest that into The Server Framework.

Why objects should keep it on the inside

So, I’m integrating this POP3 code with my server and the first thing I do is create null message store. I haven’t implemented the message store yet, so in order for me to integrate I need a message store that just says yes to everyone being a user and provides mailboxes that are always empty… The test driven development has made this reasonably easy, I have a message store interface so I just need to stub out the methods appropriately.

Does TDD lead to earlier integration?

I’m developing a POP3 server. I’ve been developing the protocol handler test first and it’s nearly done. I haven’t started on the mailstore itself yet but I could easilly integrate the POP3 code into the server code and have a functional POP3 server… Due to the test first nature of the development, the protocol handler talks to the mailstore via an interface that’s passed to it. I don’t have a real mailstore yet, but I could mock one up based on the mock mailstore from my test harness and pass this to the POP3 handler in the server.

Murphy's Law

This is a nice story about the birth of Murphy’s Law. Yes, there was really a Murphy… From the 2003 Ig Nobel prizes, via Barry.

Everyone there works on Word, I'm a bespoke tailor

Joe Bork explains why he now tells people he works on Word as a way of connecting with something people understand. I found that people seemed to understand what I did if I compared Word to a Moss Bros suit and then explained that I was a Savile Row tailor. In fact, I didn’t even come up with the analogy, one of the previously non-comprehending non-techies did. It was a family (Miche’s, not mine) Sunday lunch at The Social and I was trying to explain how, since I’m a programmer, I don’t necessarily just know how to fix all manner of miscellaneous computer setup problems and how that was more a support role… Blank looks all around.