Efficiency is all perception

A couple of things today prompted me to write about this. The first and main one was an article on Coding Horror about actual vs perceived performance.

The premise of the article and the study it references is that a user's perception of the speed of an operation is often more important than the actual speed of the operation.

This all harks back to a core software designer rule - effective feedback.

In short, if a user can see that something is happening, they're less concerned with the time it takes. This realisation no doubt led to the plethora of spinning images around the web that let you know an asynchronous request is happening. Does the rotating wheel indicate how long it will take or whether it's actually doing anything at all? No, of course not, but it is effective feedback and it inspires confidence from the user.

One of the first bits of code I wrote when I arrived at my current job was a function in an ASP.Net application that retrieved a credit report for a client. Its efficiency relied 100% on the efficiency of a server somewhere in New Zealand (there's now an Australian server). I didn't (and still don't) know before request time whether it will be available or how long the request will take if it is. I know very little about the service apart from the message it expects and the response it will hopefully give me.

At first, there were a few complaints about how long the function took. Unlike everything else in the system, it didn't respond straight away. On average, it only really took a few seconds, but it was long enough that some users wondered what was happening. Predictably, when I added a small chunk of javascript that showed a "Retrieving credit file" message and a pretty rotating circle, the complaints stopped. Because something was happening while they were waiting, albeit a simple animated gif, people were less concerned with the time it took.

I did say there were two things that prompted this post didn't I? The second was a discussion I was having with a mate about efficient methods of storing, retrieving, and sorting data. It made me think that even if you refactored your code to cut down your search from say, O(n2) to O(n log n), would your users be any happier than if you added some javascript to distract them? It's often worth investigating I think.

Damo

Damian Brady

I'm an Australian developer, speaker, and author specialising in DevOps, developer process, and software architecture. I love Octopus Deploy, Visual Studio Team Services, and reducing process waste.

Subscribe to Damian Brady

Get the latest posts delivered right to your inbox.

or subscribe via RSS with Feedly!