The following code enters GetIds
method and never return.
public static class ANameOrchestrator
{
[FunctionName(CommonNames.AName)]
public static async Task Run([OrchestrationTrigger] IDurableOrchestrationContext context)
{
var entityId = new EntityId(nameof(Documents), CommonNames.DocFlowFifo);
var px = context.CreateEntityProxy<IDocuments>(entityId);
IEnumerable<int> list = await px.GetIds();//never return or throw
}
}
I tried to wrap the method call with LockAsync
in which case the execution deadlocked on the call.
public static class ANameInOrchestrator
{
[FunctionName(CommonNames.AName)]
public static async Task Run([OrchestrationTrigger] IDurableOrchestrationContext context)
{
IEnumerable<int> list;
var entityId = new EntityId(nameof(Documents), CommonNames.DocFlowFifo);
using (var lk = await context.LockAsync(entityId)) //never goes beyond the call to LockAync
{
var x = context.CreateEntityProxy<IDocuments>(entityId);
list = await x.GetIds();
}
}
}
How to resolve the problem? What direction do I have to look? Edit using alternative version to call the entity operation doesn't work either
list = await context.CallEntityAsync<IEnumerable<int>>(entityId, nameof(Documents.GetIds));