New features
- Supports the timeout in all "wait for signal" APIs. Related ticket
Breaking changes
- IWorkflowItem.Resume APIs signature has changed. Originally you could have resume a waiting item as below
[Signal]
public WorkflowAction Cancle(WorkflowSignalEvent @event)
{
Lambda("BookOrder").Resume(@event.SignalName)
}
but now have to pass the event object in "Resume" API.
[Signal]
public WorkflowAction Cancle(WorkflowSignalEvent @event)
{
Lambda("BookOrder").Resume(@event)
}
- Polling strategy function signature has changed. Originally you would have written the custom polling strategy as below
var taskList = new TaskList("my-list");
taskList.ReadStrategy = MyCustomStrategy
...
private static async Task<DecisionTask> MyCustomStrategy(Domain domain, TaskList taskList,
string pollingIdentity, CancellationToken token)
{
var decisionTask = await domain.PollForDecisionTaskAsync(taskList, pollingIdentity , token);
return decisionTask
}
But with this release you will write as below:
var taskList = new TaskList("my-list");
taskList.ReadStrategy = MyCustomStrategy
...
private static async Task<WorkflowTask> MyCustomStrategy(Domain domain, TaskList taskList,
string pollingIdentity, CancellationToken token)
{
var decisionTask = await domain.PollForDecisionTaskAsync(taskList, pollingIdentity , token);
return WorkflowTask.Create(decisionTask);
}