6

I am working on a project which trigger the workflow in code asynchronously, the default time for the workflow timer job to pick the workflow is 5 mins , I would like to reduce the timer job from 5mins to 1 min. What is the downside of reducing the workflow timer job in SharePoint2010 from 5mins to 1 min on a Web Application.

The script to do it is as follows , I did not find the PowerShell equivalent , maybe someone can shine some light on this too?

stsadm -o setproperty -propertyname "job-workflow" -propertyvalue "every 1 minutes between 0 and 59" -url http://WebApplicationName

References from TechNet http://technet.microsoft.com/en-us/library/cc424946(office.12).aspx

3 Answers 3

6

5 minutes is a good default setting. Setting it less than that as suggested can cause additional overhead. Where I've seen it be really bad, is when it's set to one minute, and yet it takes longer than a minute to finish all of the timer jobs. I've seen cases where the timer job has hung. Really depends on the environment, number of users, and if you're willing to take the performance hit.

4

It really depends on your environment and how much workflow activity you have, but I would probably not be comfortable setting it to 1 minute in any of the environments I have worked. Setting it to 1 minute could mean a lot of increased activity and additional resources needed to support these checks. If you have heavy activity and limited resources you could start to see processor spikes and it could start taking more than a minute to process each cycle. Skipping a cycle will not cause technical problems, but will likely create confusion since the system will be inconsistent with the amount of time between runs.

1

I'm not answering directly to your question but I had recently had the same need as you to lower the timer jobs delay. I realized later on that I could use the SPLongOperation (http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.splongoperation.aspx) class to execute the long running operation I intended to execute asynchronously in the timer job.

Maybe this class is what you need too.

1
  • Cheers , I will have a look.
    – Ybbest
    Commented Dec 15, 2011 at 0:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.