What is “fast?”

It’s so easy to let our web app performance degrade as it evolves, each architectural decision and framework adding a nearly imperceptible bit of overhead to the process until eventually people start asking “when did it get so slow?” After a while, we’ve reset our expectations of what “fast” is.

I’ve been tinkering with the simplest use cases to remind myself of how fast things really can go, and it’s worth a reminder of our various orders of magnitudes. When we talk about requests/second from a single machine, what makes us happy? 10′s? 100′s? or 1000′s? These days, we’re dealing with multicore processors, each running gigahertz clocks. That means 1000′s of requests/second is still granting us millions of cycles per request. That’s a lot of instructions! [1]

On my 2+ year old laptop, Apache serves plain files at 1000 files/second. I can also get it to dynamically render a web page with a database query result at the same rate! [2]

That’s an interesting reminder of how fast things can go. Maybe it should cause us to pause and consider all our beloved abstractions and whether they are really helping us, or are they just helping us mask the inadequacies of an earlier abstraction?


[1] Yes, I know cycle != instruction, but I’m talking about orders of magnitude.

[2] I’m getting contention between JMeter and the server itself, so those aren’t upper numbers. I’m also getting benefits of OS-level IO caching.

 

One Comment

  1. Dave says:

    Numbers like this from a simple desktop make the query rates quoted from megasites like Facebook much more comprehensible. http://gigaom.com/cloud/facebook-shares-some-secrets-on-making-mysql-scale/ and the recent post on Highscalability http://highscalability.com/blog/2011/12/9/stuff-the-internet-says-on-scalability-for-december-9-2011.html The magic in making use of that power to use massive amounts of data lies in the parallelization architecture.

Leave a Reply