Channeling Bruce Lee: Tuning without Tuning
I’m leading a Performance Tuning workshop here in Portland, Oregon today, and I normally start this kind of workshop with a segment on “pre-tuning” – or, the steps you take so that you don’t have to tune as much later.
When we set up a system is the greatest opportunity for optimal performance. From buying the right hardware (like using 64-bit architectures) to configuring the drive offset, stripe and block size, to installing the proper version and edition of the Operating System and SQL Server, you’ll never have a more impactful chance to make things go fast.
That goes for you, too, developers. Unit and Integration tests are the times to find out how your code is working, and there’s little pain in fixing it in the design compared to once it’s in production. You’ll find the fastest work is that which you don’t have to do – don’t use SELECT *, that kind of thing. Ditto for the database – proper normalization, data types and index choices are key.
So take Bruce Lee’s advice about fighting: “The best fighting strategy is not to fight.” The best tuning you can do is not to have to do it much at all.