[英]Service fabric Exception
I have an async task that I run and the site is deployed using service fabric.我有一个运行的异步任务,并且该站点是使用服务结构部署的。 I am unable to identify the issue even with the full stack I have.I have no knowledge of service fabric so any help will be appreciated.
即使拥有完整的堆栈,我也无法确定问题。我不了解服务结构,因此将不胜感激。
await ServiceFabricClient.functionname(some parameters).ConfigureAwait(false)
and the stack for the exception is异常的堆栈是
System.AggregateException: at Microsoft.ServiceFabric.Services.Communication.Client.ServicePartitionClient`1+<InvokeWithRetryAsync>d__24`1.MoveNext (Microsoft.ServiceFabric.Services, Version=6.0.0.0, Culture=neutral) Inner exception System.InvalidOperationException handled at Microsoft.ServiceFabric.Services.Communication.Client.ServicePartitionClient`1+<InvokeWithRetryAsync>d__24`1.MoveNext:
Thank you Nardu .谢谢纳尔杜。 Posting your suggestion as an answer to help other community members.
发布您的建议作为帮助其他社区成员的答案。
Instead of:代替:
await restoreClient.RestoreAsync(id, name).ConfigureAwait(false);
Try this:尝试这个:
var workerId = StartANewWorker()
JobState jobState;
do {
//poll for the status of the new worker
var workerStatus = GetStatusOfTheWorker(workerId);
await Task.Delay(1000).ConfigureAwait(false);
if (workerStatus == Failed) {
throw new Exception("Something went wrong");
}
} while (workerStatus != Finished);
You can refer to await on async call throws unexpected Timeout exception and Service remoting in C# with Reliable Services您可以参考await on async call throws unexpected Timeout exception and Service remoting in C# with Reliable Services
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.