This article makes me want to HURT people
Nov. 27th, 2006 10:26 amI just saw an article on Digg called 60 Performance and Optimization Tips for your Website. The title looked cool enough, so I clicked on the link.
I was treated to intelligent observations like:
"Use a quality NIC"
"Reduce the use of global variables"
"Avoid throwing exceptions" (!)
"Enable buffering"
The first one of that bunch, "Use a quality NIC", is so vague as to be useless. It doesn't say a thing thing what sort of features we should look for, mention specific cards, or even a specific vendor.
The second one about global variables, is good advice but fails to tell WHY we should not use globals. (Hint: it has to do with conserving the global namespace and writing modular code) I don't believe in "voodoo" -- I'm not going to do/not do something because someone that is supposedly in a position of authority says so. I want to know details, dammit.
Avoiding throwing exceptions? I'd sure like to know what kind of crack of the author is on. But, since he didn't elaborate on why exceptions should not be thrown, I can only speculate his reasons for saying that. Perhaps he meant to say, "make sure you have code that catches all exceptions so that the user doesn't see a traceback if there is an error".
And finally, "Enable buffering". Sure, it's a good idea because it causes more efficient use of disk and network resources, but again, the author fails to tell us this.
The end result is a guide that has some good advice, but completely fails to educate the beginner programmer. What a terrible waste.
I was treated to intelligent observations like:
"Use a quality NIC"
"Reduce the use of global variables"
"Avoid throwing exceptions" (!)
"Enable buffering"
The first one of that bunch, "Use a quality NIC", is so vague as to be useless. It doesn't say a thing thing what sort of features we should look for, mention specific cards, or even a specific vendor.
The second one about global variables, is good advice but fails to tell WHY we should not use globals. (Hint: it has to do with conserving the global namespace and writing modular code) I don't believe in "voodoo" -- I'm not going to do/not do something because someone that is supposedly in a position of authority says so. I want to know details, dammit.
Avoiding throwing exceptions? I'd sure like to know what kind of crack of the author is on. But, since he didn't elaborate on why exceptions should not be thrown, I can only speculate his reasons for saying that. Perhaps he meant to say, "make sure you have code that catches all exceptions so that the user doesn't see a traceback if there is an error".
And finally, "Enable buffering". Sure, it's a good idea because it causes more efficient use of disk and network resources, but again, the author fails to tell us this.
The end result is a guide that has some good advice, but completely fails to educate the beginner programmer. What a terrible waste.