Add Delay Activity

Nilesh Ghodekar edited this page Oct 28, 2016 · 15 revisions


The Add Delay activity is used to fulfil requests at a precise time in the future or to introduce a delay by pausing the workflow execution for a specified timeout duration.

The runtime behaviour is similar to the DelayActivity workflow activity of the .NET Framework 3.5 Workflow Foundation. The workflow will get unloaded from memory and then reloaded into memory only when the specified timeout duration elapses.

Activity UI

Add Delay - Activity UI

Activity Display Name

Optional. Name of the activity to be displayed on the MIM / FIM workflow designer.

Activity Execution Condition

Optional. The condition which must be satisfied for execution of this activity's core task (i.e. pause workflow execution). This can be any WAL function expression resolving to a boolean value. See Activity Execution Condition wiki for more information.

Timeout Duration

Required. A Timespan string (e.g. "00:30:00") or a WAL expression returning a Timespan value (e.g. DateTimeSubtract([//Target/ExpirationTime], DateTimeNow())).

Implementation Guidance

Use this activity to introduce a delay in your workflow instead of using a Run PowerShell Script activity that executes a PowerShell script containing a Start-Sleep command. The Start-Sleep command in the PowerShell script blocks the workflow thread for the entire duration of sleep using up one of the limited pool of available ~4 maxSimultaneousAuthorizationAndActionWorkflows per CPU core.

The use of Add Delay activity causes workflow to get unloaded from memory and then reloaded into memory when the specified timeout duration elapses. Once the delay time is expired, MIM / FIM will load your workflow only on the FIMService instance on which the workflow was previously running. Hence, if that instance is down or offline when the delay time is expired, the workflow will not resume until that server is online again.

For delay of more than a day, use this activity in conjunction with a transition into or out of a Temporal Set to perform processing at a precise time to minimize the chances of host FIMService instance being offline when the time is up.


The following Add Delay activity pauses the workflow execution until the temporary privileged access is about to expire. This example uses conditional execution and the same activity configuration is meant to be used as a part of an action workflow on request submission (for short-lived privilege of less than a day) as well as on a temporal set transition (for long-lived privilege of more than a day):

Activity Display Name Wait for Privilege Expiry
Activity Execution Condition And(Not(ConvertToBoolean([//Target/xProcessedPrevilegeExpiry])), Before([//Target/ExpirationTime], DateTimeAdd(DateTimeNow(), "1")))
Timeout Duration DateTimeSubtract([//Target/ExpirationTime], DateTimeNow())
Clone this wiki locally
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.