Skip to content

More on SharePoint, Workflow, and DelayActivity

I previously commented that there were some things going on with DelayActivity, I’ve got a few more details, that should help:

Help Your SharePoint User
  • There is an issue where DelayActivity never wakes up – this is a Workflow issue that should have a fix released soon.  If you need it immediately open a product support services case.
  • Fundamentally the design of the SharePoint Workflow integration is such that it “wakes up” instead of remaining aware of timers at all times.  That means that there’s a minimum amount of time that a DelayActivity will wait.  By default it’s 10 minutes.
  • You can change the frequency down to 1 minute by executing:
    STSADM –o setproperty –propertyname job-workflow –pv “every 1 minutes between 0 and 59” –url http://%computername%

As far as my experiments go, I started into DelayActivity because the CreateTask activity needed to be dehydrated to actually create the task item.  If the workflow didn’t dehydrate the task wouldn’t be created.  This is important because I wanted to manipulate the task but didn’t want to worry about any quirks about doing it with the CreateTask representation of the task.  I added the DelayActivity to force the dehydration.  However, a better solution would have been OnTaskCreated which forces the dehydration to cause the task to be created and immediately returns to the workflow.  For every easy way there’s a hard way that I’ll take to try to solve the problem. J

No comment yet, add your voice below!

Add a Comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Share this: