当我尝试恢复Suspended(可恢复)编排实例时,出现以下错误。

场景:请求发送到DB2静态请求-响应端口,由于拒绝访问许可而失败。我可以看到管理控制台中挂起了两个实例,一个实例与端口有关,另一个实例与业务流程有关。修复凭据后,挂起的端口实例得以恢复,但编排之一继续失败。

Uncaught exception (see the 'inner exception' below) has suspended an instance of service 'Orchestration name'.
The service instance will remain suspended until administratively resumed or terminated.
If resumed the instance will continue from its last persisted state and may re-throw the same unexpected exception.
InstanceId: ca927086-465d-40e8-93fe-c3a0e4c161f7
Shape name:
ShapeId:
Exception thrown from: segment -1, progress -1
Inner exception: An error occurred while processing the message, refer to the details section for more information
Message ID: {96B72521-9833-48EF-BB2F-4A2E2265D697}
Instance ID: {F6FBC912-C9DC-489C-87F3-103FA1273FDC}
Error Description: The user does not have the authority to access the host resource. Check your authentication credentials or contact your system administrator. SQLSTATE: HY000, SQLCODE: -1000


Exception type: XlangSoapException
Source: Microsoft.XLANGs.BizTalk.Engine
Target Site: Void VerifyTransport(Microsoft.XLANGs.Core.Envelope, Int32, Microsoft.XLANGs.Core.Context)
The following is a stack trace that identifies the location where the exception occured
at Microsoft.BizTalk.XLANGs.BTXEngine.BTXPortBase.VerifyTransport(Envelope env, Int32 operationId, Context ctx)
at Microsoft.XLANGs.Core.Subscription.Receive(Segment s, Context ctx, Envelope& env, Boolean topOnly)
at Microsoft.XLANGs.Core.PortBase.GetMessageIdForSubscription(Subscription subscription, Segment currentSegment, Context cxt, Envelope& env, CachedObject location)
at Microsoft.XLANGs.Core.PortBase.GetMessageId(Subscription subscription, Segment currentSegment, Context cxt, Envelope& env, CachedObject location)
at (StopConditions stopOn)
at Microsoft.XLANGs.Core.SegmentScheduler.RunASegment(Segment s, StopConditions stopCond, Exception& exp)

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.


有什么想法如何解决?

使用示例创建以上场景:


前往BizTalk
样本/业务流程/消费Web服务
文件夹,安装
ConsumeWebService应用程序和
将POWebservice发布到IIS。
更改IIS目录安全性
POWebservice的权限,删除
匿名或其他任何访问方式。
现在删除您将看到的消息
由于HTTP而挂起的消息
状态401:访问被拒绝,然后给出
可以访问POWebservice
匿名或Windows。
然后继续
暂停的实例,
消失但是
另一个(编排)一个不会。

最佳答案

编排将继续失败并带有异常,因为在挂起该业务流程时,最后的持久点是接收到该异常。这意味着业务流程将重新开始(恢复时)并重新引发异常。

这是在这篇文章中讨论业务流程状态持久化到数据库的一些点:http://blogs.msdn.com/b/sanket/archive/2006/11/12/understanding-persistence-points-in-biztalk-orchestration.aspx

正如Richard Seroter讨论的here一样,您可以在业务流程设计中进行某种程度的操纵,但是通常最好使用failed message routing,使您能够处理失败的消息并终止失败的业务流程实例。

09-05 20:12