Edited - Seems that my original question didn't explain what I wanted clearly enough
What I would like to do is use Windows Workflow to handle action requests. I know WF is quite heavy and difficult to work with, but I haven't found any other .NET-based workflow libraries that suit this task.
Does anyone have any examples on how to do this? Or has anyone tried it? Whether or not this is "true MVC" is not important.
Edit: The "fat controller" example I posted was simply an example of one of the reasons why I want to add WF - All other logic is encapsulated in other service/business layers, and the only thing the controller is responsible for is calling these services and determining the view to be displayed. To me, it makes sense to make this UI-specific controller code editable - especially in the CMS framework I'm working on. This is why I want to use Workflow (I have created a jQuery-based XOML editor)
Just to clarify my original question: I'm not trying to move all my business logic into workflows in an attempt to tidy up my classes, I'm trying to move the reusable Controller/UI logic from out of compiled classes into distributable XOML files.
For example, many of the controller/actions I write are:
public ActionResult List(string categoryId) {
if (String.IsNullOrEmpty(categoryId))
{
var data = productRepository.GetCategories();
return View("ListCategories",categories);
}
var data = productRepository.GetProductsByCategory(categoryId);
return View("List",data);
}
public ActionResult Display(string productId) {
var product = productRepository.GetProductsById(productId);
return View("Display",product );
}
These actions are thin enough to be able to be extracted into Workflow Activities which can then be defined via a drag-drop interface.
I'm currently working on a custom CMS project and would like to use a jQuery web-based xoml editor I created a while ago to define the actions available in the application. The developer section of the admin UI is already capable of generating/editing data models and views - I would like to be able to define simple controller actions using the UI as well. I have placed all other service/business logic in either extension methods or service classes.
I intend to export these as XML-based modules, so they can easily be ported from one website to another. Most of the websites I will be creating are very similar, so there isn't a lot of custom code required.
Obviously, some complex Controllers may not be suitable and require their own custom controller class, but it would be useful to be able to simply modify the workflow to introduce, for example, a new "filterByEmailAddress" parameter on WebsiteB, while WebsiteA still retains the original filters.