活动工作流程与运行工作流程

发布于 2024-11-15 08:02:29 字数 156 浏览 8 评论 0原文

本周末在伊利诺伊州莱尔举行的 SharePoint Saturday 活动上,Robert Bogue 表示活动工作流和正在运行的工作流之间存在差异。我在网上查了一下,有人能解释一下吗?

如果服务器上可以有多达数百万个活动工作流程,为什么每台服务器只能运行 15 个左右的工作流程?

At SharePoint Saturday in Lisle, IL this weekend, Robert Bogue said there's a difference between active and running workflows. I've looked on the web, but can someone clarify?

If I can have up to millions of active workflows on the server, why can I only have 15 or so running workflows per server?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

看轻我的陪伴 2024-11-22 08:02:29

是的,有区别:

  • “正在运行”工作流程是当前正在执行某些操作(即执行活动)的所有工作流程。
  • “活动”工作流程只是所有正在“运行”但当前没有执行任何操作的工作流程 - 例如等待OnItemChangedDelayActivity

理解这一点的关键是 WorkflowEventDeliveryThrottle(此处适用于 SP2007,因为 2010 的文档不存在)。该属性的标准值为 15。这意味着只有 15 个并发工作流可以同时运行。达到此限制后,工作流将排队到 OWSTimer 中,该 OWSTimer 在任意时间后执行工作流(我认为工作流计时器作业设置为每 5 分钟一次)。

可以使用 stsadm 更改此 Throttle(据我所知 Powershell 不起作用 - 您可以通过课程设置 SPWebService.WorkflowEventDeliveryThrottle 的代码更改属性):

stsadm -o setproperty -pn workflow-eventdelivery-throttle -pv "20"

现在最大数量“正在运行”的工作流程(最好是“可以同时处理的工作流程事件的最大数量”)为 20。请参阅一些其他 SO 帖子,其中有人使用该参数。

有一篇很好的技术博客文章可以帮助您了解工作流事件处理:关于“workflow-eventdelivery-throttle”参数

与限制类似的是 WorkflowEventDeliveryBatchSize 表示批量处理的工作流事件的最大数量。


Summary:

  • 您可以拥有数千个活动工作流程,例如所有工作流程都在等待工作流程项发生更改。它们没有运行,也没有结束——只是活跃。
  • 可以同时处理的工作流程事件数量有限(您将其称为“正在运行”的工作流程)。
  • 您还可以有数千个正在运行工作流程,例如所有其中一些可能会被设置为 5 分钟的延迟活动触发,但只有有限数量的它们同时运行,其余的则排队等待稍后执行。

Yes, there is a difference:

  • "Running" Workflows are all which currently are doing something (i.e. executing an activity).
  • "Active" Workflows are simply all which are "running" but currently are not doing anything - e.g. waiting for OnItemChanged or DelayActivity.

The key to understand this is WorkflowEventDeliveryThrottle (here for SP2007, because the documentation for 2010 doesn't exist). The standard value for this is property is 15. That means that there are only 15 concurrent workflow which can run at the same time. After this limit is reached the workflows get queued to the OWSTimer which executes the workflows after some arbitrary time (I think the workflow timer job is set to every 5 minutes).

This Throttle can be changed by using stsadm (AFAIK Powershell doesn't work - you can change the property via code of course setting SPWebService.WorkflowEventDeliveryThrottle):

stsadm -o setproperty -pn workflow-eventdelivery-throttle -pv "20"

Now the maximum number of "running" workflows (better would be "maximum number of workflow events that can be processes simultaneously") would be 20. See some other SO post where someone plays with the parameter.

There is a nice technical blog post to understand Workflow Event Processing: About the “workflow-eventdelivery-throttle” parameter.

Similar to the throttle is the WorkflowEventDeliveryBatchSize which denotes the maximum number of workflow events that are processed in a batch.


Summary:

  • You can have thousands of active workflows, e.g. all waiting for the workflow item to be changed. They are not running, not finished - simply active.
  • There is a limited number of workflow events that can be processed at the same time (you called it "running" workflows)
  • You could also have thousands of running workflows, e.g. all of them might get triggered by a delay activity set to 5 minutes, but only a limited number of them is running simultaneously, the rest of them gets queued for later execution.
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文