简体   繁体   English

Workflow Foundation 4.5异常处理

[英]Workflow Foundation 4.5 Exception Handling

I have a very simple, long-runnig, message based, WCF Workflow and I'm facing a problem because whenever I have to throw a exception back to the who sent a message to the workflow, even if its by propous (i mean that the exception raised was mistakenly not treated...) the workflow instance goes to a "failure" state that cannot be continued... 我有一个非常简单的,长期运行的,基于消息的WCF工作流,并且遇到了一个问题,因为每当我不得不向发送消息给工作流的人抛出异常时,即使它是偶然的(我的意思是,引发的异常错误地未得到处理...)工作流实例进入无法继续的“失败”状态...

what i want is to know how to turn this off... say like don't change the state of the workflow to "error"! 我想要的是知道如何关闭此功能……说不要将工作流程的状态更改为“错误”! something in the order of "throw and continue"... 按照“抛出并继续”的顺序进行操作...

You need to implement a WCF FaultContract on your Receive/SendReply pair. 您需要在Receive / SendReply对上实现WCF FaultContract。

See this article http://msmvps.com/blogs/theproblemsolver/archive/2010/03/24/workflow-4-and-soap-faults.aspx 看到这篇文章http://msmvps.com/blogs/theproblemsolver/archive/2010/03/24/workflow-4-and-soap-faults.aspx

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM