工作流设计建议为ASP.Net Web应用程序? [英] Workflow design advice for ASP.Net web application?

查看:175
本文介绍了工作流设计建议为ASP.Net Web应用程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的团队一直负责设计是工作流驱动的Web应用程序。我需要有关设计一些建议。

My team has been tasked with designing a web application that is workflow driven. I need some advice regarding the design.

的工作流程需要是动态的。这意味着,用户可以定义通过一些接口的工作流程和应用这些工作流程,以给定的情况下(的定义将生活在一个SQL 2008数据库)。这些方案由业务定义,永远不会改变。所以有可能只有2类型的方案的工作流可以被定义。工作流不一定是线性的。一些国家将推动工作流程。态也将是动态的,但只能在一个流中存在

The workflows need to be dynamic. Meaning, users can define the workflows through some interface and apply those workflows to a given scenario (The definitions will live in a SQL 2008 Database). The scenarios are defined by the business and will never change. So there may be only 2 types of scenarios a workflow can be defined for. The workflows are not necessarily linear. Some sort of state will drive the workflow. States will also be dynamic, but only exist in a workflow.

我一直在寻找的工作流程和状态机的例子,我的头在旋转。我不知道我想用杠杆Workflow Foundation的什么,我们的发展。我所看到的并认为它可以工作,但我不知道国家全面实施将工作为了我们。

I have been looking at examples of workflows and state machines and my head is spinning. I am not sure I want o leverage Workflow Foundation or something we develop. I have seen this and think it may work, but I am not sure the state full implementation will work for us.

推荐答案

您可以使用WF4做到这一点。我从来没有使用Objectflow所以我真的不能对此发表评论,但它似乎是一个内存解决方案,并在IIS中,这意味着你将失去偶尔状态,IIS和回收的AppDomain主办的ASP.NET网站。通常不是一个大问题,因为它不经常发生,但一个WF4 InstanceStore将采取照顾。它还可以让你在没有粘性会话Web场运行,并有工作流程,从机迁移到机器。

You can do this using WF4. I have never used Objectflow so I can't really comment on that but it appears to be an in memory solution and with an ASP.NET web site hosted in IIS that means you will occasionally lose state as IIS recycles and AppDomain. Usually not a big problem as it doesn't happen often but a WF4 InstanceStore will take care of that. It will also allow you to run on a web farm without sticky sessions and have the workflow migrate from machine to machine.

另一个好处是工作流设计器。它是一个WPF控件,你可以在自己的应用程序重新宿主。不是上午ASP.NET或Silverlight应用程序,但你可以提供一个智能客户端让用户用理智的设计更新工作流定义,如您在VS2010使用。

Another nice thing is the workflow designer. Its a WPF control you can rehost in your own app. Not in am ASP.NET or Silverlight app but you can provide a smart client to have users update the workflow definition using the sane designer as you use in VS2010.

与WF4的最大问题是异步执行的性质。您将需要使用的SynchronizationContext来执行的活动和等待工作流程去闲置在新的状态返回生成的HTML的浏览器。

The biggest problem with WF4 is the asynchronous execution nature. You will need to use a SynchronizationContext to execute the activities and wait for the workflow to go idle in the new state before you return the resulting HTML to the browser.

这篇关于工作流设计建议为ASP.Net Web应用程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆