Fat ASP.NET MVC Controllers

Posted by Mosh on Stack Overflow See other posts from Stack Overflow or by Mosh
Published on 2010-03-12T05:46:27Z Indexed on 2010/03/12 5:57 UTC
Read the original article Hit count: 373

Filed under:
|
|
|

Hello,

I have been reading about "Fat Controllers" but most of the articles out there focus on pulling the service/repository layer logic out of the controller. However, I have run into a different situation and am wondering if anyone has any ideas for improvement.

I have a controller with too many actions and am wondering how I can break this down into many controllers with fewer actions. All these actions are responsible for inserting/updating/removing objects that all belong to the same aggregate. So I'm not quiet keen in having a seperate controller for each class that belongs to this aggregate...

To give you more details, this controller is used in a tabbed page. Each tab represents a portion of the data for editing and all the domain model objects used here belong to the same aggregate.

Any advice?

Cheers, Mosh

© Stack Overflow or respective owner

Related posts about ASP.NET

Related posts about mvc