具有相关性的重复工作流程

发布于 2024-10-10 07:48:32 字数 204 浏览 0 评论 0原文

我有具有相关性的工作流程。当我使用相同的参数调用某个方法两次时,出现以下错误:

InstancePersistenceCommand 的执行因按键冲突而中断。值为“bcd874f3-1d47-d9f0-de51-4487d1e4e12e”的实例密钥无法与该实例关联,因为它已与另一个实例关联。

有没有办法删除以前的工作流程并开始新的工作流程?

I have workflow with correlation. When I call twice some method with the same parameters i have the following error:

The execution of an InstancePersistenceCommand was interrupted by a key collision. The instance key with value 'bcd874f3-1d47-d9f0-de51-4487d1e4e12e' could not be associated to the instance because it is already associated to a different instance.

Is there any way to delete previous workflow and start new?

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

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

发布评论

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

评论(1

小梨窩很甜 2024-10-17 07:48:32

您可以将 WorkflowControlEndpoint 添加到 WorkflowServiceHost 并使用 WorkflowControlClient 在使用以下命令启动新工作流之前终止现有工作流相同的相关键。

You can add a WorkflowControlEndpoint to the WorkflowServiceHost and use the WorkflowControlClient to terminate the existing workflow before starting a new one with the same correlation key.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文