A lot of companies have a couple of technical people who are responsible for laying down some technical guidelines, rules, or even reusable libraries or small (or large) frameworks. The idea is that all the developers within the company (or department) need to follow the same rules, use the same libraries, and pretty much write similar code compared to everyone else. I'm not going to get into the benefits/drawbacks of this, but there is one important aspect of this approach that i've seen in a few places which i'd like to comment on.
What you often see in this kind of situation is that the people who make up the rules (let's call them the 'technical leads' for the purpose of this post) often try to protect less-skilled developers from making mistakes or even assume that less-skilled developers won't be able to comprehend certain technical principles/aspects/patterns/approaches. Btw, i don't mean the term less-skilled developers in a derogatory way... but that is often how technical leads in places like these think of 'application developers', especially those who still have a lot to learn. This often leads to guidelines, or even API's which are heavily influenced by the perceived lack of skills/insight/knowledge of the less-skilled developers.
I'm sure you all have countless examples of situations where technical leads impose restrictions or guidelines based purely on their lack of faith in less-skilled developers. Hell, just browse through Microsoft's Framework Design Guidelines and you'll encounter quite a few more examples of how some of the .NET Framework's technical leads made choices or still recommend certain things based largely on having to deal with less-skilled developers who might not have the required skills to do everything the proper way. (Side note: i do like the FDG book and find it quite helpful in many situations, though the parts where they talk about less-skilled developers really do annoy me).
In the large majority of cases, trying to protect developers from themselves is just not worth it. For starters, hiding things from developers often requires more effort in the long run than simply trying to educate your developers as to how they should properly do their job. Sure, you can wrap anything that you deem as potentially easy-to-misuse, but you will need to think about alternative approaches whenever you have to deal with a situation in an application that falls outside of the boundaries you had in mind when you wrote your wrapper. And this is where it usually gets very messy, very quickly.
On the other hand, you could have invested some amount of effort into guiding and teaching those developers who you might consider as less-skilled. If you're going to hide things from less-skilled developers, how can you possibly hope that these developers will one day require less hand-holding and protection from themselves? The only way these developers are going to reach the level you'd like them to be on, is if somebody is going to help them get to that level. It might not always be easy, but it's usually far more effective in the long run than simply having to deal with their (perceived) lack of skill forever and ever.
Another huge downside to protecting developers from themselves is that it easily puts off the strong developers. Just imagine that you join one of these companies/departments where they do this. You know the ins and outs of certain libraries or frameworks, yet you are being restricted because the powers that be don't want your less-skilled coworkers to screw up. How likely are you to stick around for a long time in a place like this? How motivated could you be, knowing that you'll often be restricted on a technical level?
Basically, there are 2 huge downsides to this. The first is obviously that your less-skilled developers are never going to improve. You will be stuck with their perceived inabilities forever. The second is that it will either drive your competent developers to look for a better job, or if they stick around they might tune out, which could lead to a whole other host of problems. All of this can easily be avoided by simply showing your willingness to help educate your developers. They will benefit from it, and as a result, so will you.
Pingback: Educate Developers Instead Of Protecting Them | The Inquisitive Coder – Davy Brion’s Blog « Jay Nathan
Pingback: » A Smarter Infrastructure: Automatically filtering an EF 4.1 DbSet Clarity Blogs