____________________________________
BackgroundWorker vs async/await
I wanted to see the benefits and drawbacks of moving my Windows service template from its current event-based asynchronous pattern (EAP) with the BackgroundWorker type to the more modern task-based asynchronous pattern (TAP) with async/await. The BackgroundWorker type still has its place, primarily with background operations behind a desktop UI. But there's no UI in a Windows service, so it's potentially an interesting place to explore the switch. Read more
27-Dec-2015 00:30
____________________________________
Software quality defined by size of bonus?
In any line-of-business company, some end-users and senior stakeholders are focused on building and releasing important functionality as fast as possible. For these people, short-term velocity is the key attribute, as long as the software is reliable enough to give the right results at the right times - for given, often unspecified, values of "right". Crudely speaking, the quality of software is defined by the size of their bonus that year. Read more
20-Dec-2015 23:00
____________________________________
Somebody asked me what technologies had recently piqued my interest, and in what ways.
I'm usually more focused on solving interesting and/or hard problems, rather than on the technology itself. Without a specific grounding in the business problem, any technology-related changes that you make (for example, introducing NoSQL) will be built on a weak foundation and can be fragile and prone to disintegration.
Having said that, I'm just pushing the question one level down the stack.
Read more14-Dec-2015 22:00
____________________________________
Following on from the last simple question, here's another: "What is VAR?" Again, a simple question deserves a (relatively) simple answer, so that's what I've tried to do below.
Let's assume you have a portfolio of shares worth 1M USD. What's the maximum you could lose over the next day or month or year? Without an answer to this question, you can't tell whether the return you're receiving on your portfolio is appropriate compensation for the risk of holding it.
Read more09-Dec-2015 22:50
____________________________________
What do energy trading companies do?
A software developer asked me a simple question: "What do energy trading companies do?" A simple question deserves a (relatively) simple answer, so that's what I've tried to do below. Read more
30-Nov-2015 13:20
____________________________________
13 lessons from agile projects
Over the years I've had the chance to work on many line-of-business software projects in various roles: developer, project manager, delivery manager, and solution/data/technical architect. This have given me some interesting insights into different flavours of the agile process. Here are some of the lesssons that I've learned. Read more
29-Nov-2015 13:15
____________________________________
Squirbling with "Hello World!"
There's an interesting, if now rather old, programming challenge on the Programming Puzzles & Code Golf StackExchange website. The task is to create the weirdest obfuscated "Hello World!" program using the language of your choice, but with the restriction that you cannot use any strings. Read more
18-Nov-2015 22:15
____________________________________
A link dump of some of the better videos I've seen over the past couple of years. Beware, some of these videos are most definitely NSFW because of the language used.
Read more22-Sep-2015 17:15
____________________________________
A reusable Windows service template - part 3
This is part 3 of a 3-part series that discusses a reusable Windows service template designed to:
- Provide all of the service infrastructure, so that the developer can focus primarily on the real work that the service does.
- Create a service infrastructure that starts/restarts, monitors, and logs the worker thread where the service's work is occurring.
- Isolate the service's work from the controlling infrastructure so that any crash is logged properly and doesn't bring down the service.
- Have relatively simple and small code, so that it's easy to understand, maintain, and debug.
- Enable the developer to test and debug the service within Visual Studio.
- Allow the service to install and uninstall itself from the command-line, without the use of InstallUtil.
- Avoid any cross-thread interactions that involve polling or "busy" loops.
- Reduce application-level cross-thread interactions that involve shared memory.
- Log everything that the service is doing, and especially cross-thread interactions.
11-Oct-2014 17:15
____________________________________
A reusable Windows service template - part 2
This is part 2 of a 3-part series that discusses a reusable Windows service template designed to:
- Provide all of the service infrastructure, so that the developer can focus primarily on the real work that the service does.
- Create a service infrastructure that starts/restarts, monitors, and logs the worker thread where the service's work is occurring.
- Isolate the service's work from the controlling infrastructure so that any crash is logged properly and doesn't bring down the service.
- Have relatively simple and small code, so that it's easy to understand, maintain, and debug.
- Enable the developer to test and debug the service within Visual Studio.
- Allow the service to install and uninstall itself from the command-line, without the use of InstallUtil.
- Avoid any cross-thread interactions that involve polling or "busy" loops.
- Reduce application-level cross-thread interactions that involve shared memory.
- Log everything that the service is doing, and especially cross-thread interactions.
08-Oct-2014 23:50
____________________________________
A reusable Windows service template - part 1
This is part 1 of a 3-part series that discusses a reusable Windows service template designed to:
- Provide all of the service infrastructure, so that the developer can focus primarily on the real work that the service does.
- Create a service infrastructure that starts/restarts, monitors, and logs the worker thread where the service's work is occurring.
- Isolate the service's work from the controlling infrastructure so that any crash is logged properly and doesn't bring down the service.
- Have relatively simple and small code, so that it's easy to understand, maintain, and debug.
- Enable the developer to test and debug the service within Visual Studio.
- Allow the service to install and uninstall itself from the command-line, without the use of InstallUtil.
- Avoid any cross-thread interactions that involve polling or "busy" loops.
- Reduce application-level cross-thread interactions that involve shared memory.
- Log everything that the service is doing, and especially cross-thread interactions.
08-Oct-2014 23:45
____________________________________
It's well understood that developers, and especially line-of-business developers, spend much more time reading and understanding existing code than writing new code. Yet one of the most common interview approaches emphasises writing new code.
So one of my standard developer interview questions is to give the candidate a few lines of rather dodgy code and ask the following:
- Explain what the code is doing.
- Explain any significant issues with the code.
- Explain how to prioritise the issues.
- Explain how to fix the issues.
09-Feb-2014 16:00
Engineering in the white spaces


