Context switching

I’m at work.

And I know what you’re thinking.


Logs onto his own blog when he should be working?! When are we going to get 150 character tweets, if the developers all spend their days on personal blogs?

I hear you.

But I’m getting old. With old age comes a certain amount of experience, a certain amount of stiffness in the bones, a certain grey-haired softly-spoken cynicism of newfangled inventions.

But as far as coding goes, the biggest effect is context switch pain.

I feel sure that when I was twenty I could happily flip between six different projects, in seven different languages, for eight different clients. I could jump contexts like a frog that dodges traffic in an old computer game.

Now I’m over a hundred, I find this harder. Come over and ask me about your project, and my thought processes go like this:
– what?
– what’s happening?
– try to remember current task
– who is this?
– does it look urgent?
– if I ignore them any longer, will they just go away?
– save
– remove headphones
– try to work out what I spoke with them last about
– ask them to repeat what they’ve been saying for five minutes.

The whirl of my mind is a bit like that special effect in Butterfly Effect where there’s a kind of wobbly text, whoosh, whoosh, and I have no idea what’s going on.

When I’ve finishing talking about their problem, I turn back to my computer. Rebooting the brain goes like this:
– what is this?
– what was I doing?
– email
– check name of git branch
– look up relevant ticket
– resume coding
– who’s this?
– does it look urgent?
… and the process continues.

Some tricks I’ve discovered to help with this:
– just don’t use facebook
– name my git branches something sensible
– try to work on one thing at a time
– keep my todo list in jira.

It mostly works. Mostly.

And why am I blogging?

My tests are running. Usually I’d switch to another branch and carry on working. Today, with a five am baby feed to start the day, I’ll settle for one thing at a time.

Tests complete. Back to work.


Everyone talks about what makes a great manager. Inspirational, motivational, aspirational. But a great project manager is a different kettle of fish. Or a kettle of different fish. Maybe goldfish.

Whatever. Different.

Let me tell you a story of many years past. I was working closely with my PM on a significant project for a major car company (I’ve actually worked for most of them).

My PM’s job was to protect me from all the political, contractual rubbish that comes with any large project, to allow me to focus.

When we went to meet our partner company for this contract, we divided up. Techies in one room, project managers in another. Hey, we only had an afternoon. It meant we could focus.

The trouble was that without project managers, we had no idea who was supposed to do what. We divided up the work as we saw it, not the way the contract, budget, or the project plan that had been drawn up in the other room, had expected.

As the project progressed, the levels of insulation increased. I was excluded from status meetings, client meetings. I was still working to my own plans.

Months of hard work later, we were significantly out of step. Expectations didn’t meet product.

Deadlines passed. Clients fumed. Rivers of blood. Earthquakes rent the land. Trees fell. Floods. Weekend work. Fire. Brimstone. The works.

At Twitter we have a core value, to “communicate fearlessly to build trust”. It’s my favourite value. It doesn’t say communicate *needlessly*, so I don’t need to know what you have for breakfast, or how much the CEO earns.

But it speaks to transparency and openness, and I’ve learned that this is what makes a great Project Manager.

Instead of standing between the engineers and the rest of the company, they serve as a connector, bringing you news, making introductions, setting up meetings. Not telling me what I need to know, but telling me everything I might want to know.

A connector, not a shield. That’s a great PM.


With nine months of real work experience under my belt, I felt I knew everything. It was time to branch out and be a contractor, earning the fabled bucketloads of cash. In my early career, life was simple like that.

Sadly, the dotcom bust had just taken place, so finding a contract wasn’t so easy. I almost asked for my old job back.

But by March 2001, I found myself at eMCSaatchi, the digital arm of M&C Saatchi, working on the Rover website.

The team had about a dozen techies. Almost all of us were contractors. Everyone else was making double the money I was, but hey, I had to make rent. So here I was.

My primary project was completing a car configurator. This showed you the various options for the cars, in which combinations you could buy them, and the resulting price.

My JS-based page was a placeholder, soon to be replaced by the work of the two Java programmers and the database guy. I finished up the project fairly easily, based off a set of brochures. It had a lot of programmatic rules, covering colour combinations and the like. My page only covered the UK combinations.

I spoke to the others. It turned out that they hadn’t even started work yet. They were just sitting there, thumb-twiddling!

Nobody had given them a spec yet. They were waiting to get in touch with Rover’s IT department, which they were confident would just have data on hand, ready for export. The project manager, Mike, a sound bloke, was going crazy with frustration.

Finally, they got their meeting. Poor Mike had to drive all the conversation. It transpired that their database covered only manufacturing, not sales. The two are not really connected – not even close.

So I spoke to our database guy. What was our plan?
Oh, he said, we wait for them to connect databases, give us the export.
But that’ll take months!
Well, we need the spec.
But we know the spec, I say. Surely it’s a simple relational database? Cars all have four wheels, one engine, and so on.
Ah, he says, but you don’t know that.
What? I say. You can’t have a car with two engines!
You don’t know that until we get the data! Maybe they will?
What? I said, I *have* the data. Look, it’s here in these brochures.
Ah, he says, but we want a generic configurator. So we can sell it to other clients if we want.

I got nowhere. I couldn’t understand his lack of interest in just getting the job done.

So I went home.

And I thought about it.

And I came back to work.

I spoke to Mike. I think, I said, this is silly. How about I go home this weekend and build you this configurator? Obviously you’d pay me a little extra. But you’re getting nowhere right now.

Deal, he says.

Now, I don’t want to toot my own horn too much here. By this time, I knew the car specs inside out. It was Easter weekend – I had four clear days. And I worked a good 14hours a day. But by Tuesday morning, I had it working.

A bit rough around the edges, hanging off CSV files and perl, but working. And, generic. You could configure anything with this thing.

It caused a storm.

Two weeks later, the database guy was out. Mike was happy, probably for the first time in his life. The Java guys spent a month recoding it into XML and Java, for internal consistency. This is really clever, one said. You could configure a kitchen with this.

But my first fail was in getting paid. I handed it over too soon. They promised, and promised, then made excuses, then apologised, and gave me just 32hours pay.

The second big shock came after launch. We’d got one country out, it was beginning to work.

And they let me go.

I’d saved the company a fortune, delivered on time, and worked myself out of a job.


But it wasn’t a complete loss. Six months later, they were struggling to deliver. The system needed an update, needed support. To prevent losing their most lucrative client, they needed a big change. First on that list? “Hire kpk”

Mike gives me a call. “How much do you want?” he says.

Twenty seven

My first real job was at a company called AKQA. Nobody ever knew for sure what the letters stood for.

I’d been working, for fun, in an off license in South Croydon, while attempting to run a web design startup. The startup was going well, save for the fact that I didn’t have a clue what I was doing, had no clients, no business skills and very little money. So, I thought, time to get a job.

Two weeks later, I was in. I’d had a 20 minute interview, at least half of which was spent admitting I knew no ASP at all but knew my HTML, and the other half was them persuading me to join. I took it for 20 grand a year.

First day on the job, I had to build my own desk. Seriously. They just pointed to a corner and a power screwdriver. Then I spent that week reading their ASP coding standards. I have still never written any ASP.

At the first opportunity, I jumped into some JavaScript. The guy I was working with, full of tall tales and brag, was struggling with a sliding bar. He’d copied some code from dynamic drive, but was then lost. “I’ve got it all done,” he said, “I just can’t make it slide right instead of left.”

I read the JavaScript book that week. Loved it. Memorised most of it.

We were working on a site for Littlewoods, a catalogue retailer. It was good, it had some fun quirks. The backend was written by some muppets from Oracle. We had no JSP back then, so they’d repurposed the span tag for server side markup. Weird.

As the site rolled out, the problem was always speed, and in those days that meant your modem. 28k was standard. The office couldn’t even manage that. We had a couple of ISDN lines shared between 150 of us.

Yes, 150. This company was the shit. All the major players worked with them. There was money coming out of their ears.

Not ours, you understand. There were no stock options. In fact, shares were divided (unequally) between the four founders – who were the oldest people at the company.

They were twenty-seven.

Anyway, site performance was key. Towards the end, I’d realised that I could just duplicate HTML on the fly for each item, reducing the bandwidth of the download by about fifty percent. I also wrote a clever tool that used LZW compression on the HTML, decoding with JS.

We didn’t go with either – they caused too many crashes. It was too far ahead of its time.

The other project I worked on was for Saga, the over-fifties club. They were huge, and just wanted us to build pretty templates for their own teams to build out. I picked up the project late – just bug fixing and a workshop to run.

The design we had was awful – it locked the site into a box designed for 800×600 screens. There was no space for any text, so we had to have custom scrolling boxes, each only showing a sentence or so. All this for old people. Terrible.

Of course, this was before accessibility (and apparently common sense) had been invented.

My major cockup in all this was the workshop. They’d paid an overhead for this, maybe 30k, I don’t know. But I hadn’t been briefed – I had absolutely no idea what they expected from it, or who would be there. I figured I could bluff it, talk them through the site.

We got there to find a room full of random people. From the IT manager of one team, to the press guy who wanted to know about the website. None of them knew what they wanted either.

I sat down at the computer they’d prepared. Everybody crowded round.
Netscape. Shit. Well, ok.
No Internet. Shit. But ok.
I pop the CD in from the office.

There was nothing there. I had nothing to show, nothing I could present.
When I got back to the office the next day, I asked the guy who prepared the CD why he hadn’t put the stuff on there as promised. “Oh,” he said, “it didn’t fit.”

So, yeah, what do you do?

I wore the shame of that awkward encounter for about a week. I still kick myself over it.

I quit soon after, but not because of that. I was young. Didn’t mind making mistakes. I’d already been promoted to tech lead, but I had no clue. I left in search of fame and fortune. It was December 2000. The bubble had burst, and the next job was harder to find.

Before I left, I hired this guy for my team called Dan. He wore huge trousers. But he was really smart. Got up to speed on everything in no time.

We kept in touch.
He’s now my Engineering Manager at Twitter.