-
Notifications
You must be signed in to change notification settings - Fork 5
Retries and Polling
Andre edited this page Oct 25, 2022
·
7 revisions
Microflow retries is an extension of Durable Function retries. A workflow has a default retry object that can be set. A step can override the default with it`s own retry object that is settable per step. Any steps with no retry object set will use the workflow default retry.
-
RetryOptions
RetryOptions
: This is the default retry object of the workflow.
-
RetryOptions
RetryOptions
: This can be set per step to override the default retry options of the workflow.
public class RetryOptions
{
public int DelaySeconds { get; set; } = 5;
public int MaxDelaySeconds { get; set; } = 120;
public int MaxRetries { get; set; } = 15;
public double BackoffCoefficient { get; set; } = 5;
public int TimeOutSeconds { get; set; } = 300;
}
Microflow will poll in these cases:
- When a workflow is paused during execution.
- When the maximum allowed concurrent count of a scale group is reached - polling to check if the next step can execute.
- When a workflow is started but is paused.
- A step call-out can be set to poll by setting AsynchronousPollingEnabled to true. This is the 202 ACCEPTED pattern.
Polling settings can be set in the local.settings.json file. This one set of polling settings is applicable to polling cases 1 to 3 but not to a step`s AsynchronousPollingEnabled property:
"PollingMaxHours": 240,
"PollingIntervalSeconds": 5,
"PollingIntervalMaxSeconds": 15
-
AsynchronousPollingEnabled
bool
: If this is set to true, then the step call-out will poll for a result if it receives a 202 accepted reply.