in

 

AgileJoe

Answering all world issues with, "...it depends..."

Convention over Configuration: The Haack Response

Yesterday Sean and I talked briefly about Convention over Configuration and how disappointed we both were on MS direction requiring the [ControllerAction] attribute for each action in the controller.  Similar sentiments seen in Ayende's post as well. 

Less than a day later Phil Haack responds with a "ConventionController".  This controller gives the convention approach to the ASPMVC framework similar to MR.  I figured it shouldn't be that difficult for MS to implement this approach and Phil expeditiously verified that. 

Hat's off to Phil for getting this turned around so quickly and listening to the community.

Comments

 

schambers said:

Cheers to that.

I'm very happy that the community say this type of turn around. It definitely alleviates my doubts =)

December 9, 2007 6:26 PM
 

Ben Scheirman said:

Yeah that's really easy to implement, but I have to ask:

Why in the world do we care about 1 extra attribute?  Write a R# template of VS code snippet and be done with it.

December 10, 2007 11:50 AM
 

Joe Ocampo said:

@Ben

Luckily I just answered this question.  :-)

<copied>

Just because we have been doing it doesn't mean we have to continue.

I hate to use this but we are like a bunch of lemming s sometime and we just fall in with the standard MS conventions.

MR and RoR have been very successful with the Convention over Configuration approach.  And I think for us to turn a blind eye towards this approach simply because MS want to change it is a disservice to the community.

A majority of the MVC framework takes a convention over configuration approach (ie the folder structure).  This slight decoration causes a shift in that way of thinking.  It is not about a matter of style as it is a matter of adhering to framework principle no matter how esoteric they may be to new comers.

The fact of the matter is all we are asking for is a choice and I believe Phil and the rest of the MVC team has given us this with the "ConventionController" so now it truly is a matter of style.

Although I do like Scott's suggestion about the controller defaulting to this behavior and forcing the "SafeMode" when needed.  Similar to VB's option explicit.

</copied>

December 10, 2007 12:20 PM

Leave a Comment

(required)  
(optional)
(required)  

Enter the numbers above:
Add
Copyright Los Techies 2007. All rights reserved.
Powered by Community Server (Commercial Edition), by Telligent Systems