How do I run a Timer job in SharePoint 2013 that acts as a Contributor when kicking off multiple 2013 workflows?

I want to make a Timer job in 2013 (I am on-prem) that can start up multiple workflows. These workflows need to run in a user context that has contribute access to the whole site collection. I understand that by default the Timer job runs as the user context of the OWSTimer service (farm account) and that account is not allowed to kick off workflows.

Can I specify that a workflow start as a specific user? Also, we are using Claims authentication and Negotiate (Kerberos) is the first provider and NTLM is the second (in IIS this is visible / configured). Thanks!

August 25th, 2015 3:24pm

Hi,

According to your description, my understanding is that you want to start multiple workflows using timer job.

I suggest you start multiple workflows using PowerShell and auto-run it many times using windows task

About how to start workflow using PowerShell for your reference:

http://www.c-sharpcorner.com/Blogs/47881/how-to-start-workflow-in-sharepoint-2013-using-powershell.aspx

How to schedule a task:

http://windows.microsoft.com/en-US/windows/schedule-task#1TC=windows-7

Best Regards,

Dean Wang

Free Windows Admin Tool Kit Click here and download it now
August 26th, 2015 10:42am

This is not a valid answer.
August 26th, 2015 1:49pm

Let me clarify: The Timer job will run every 15-30 minutes. It needs to run as a user account that has access to all documents in a document library. It needs to start a particular 2013 workflow on each document and the 2013 workflow must run in the context of this "administrative" user. 

My understanding is that a Timer job runs as a system account (farm account). The farm account cannot start 2013 workflows by Microsoft design. Therefore I need the Timer job to "impersonate" another user that does, in fact, have this level of access.

Free Windows Admin Tool Kit Click here and download it now
September 1st, 2015 5:59pm

Hi,

In SharePoint 2013, scheduling workflows with Windows Task is very common. The timer job is by design running under the farm service account as you mentioned, and I don't think it is possible to impersonate another user acount to run a timer job in SharePoint. Instead, you can call an external web sevice in your custom timer job, and from the external service, you can make remote call back to SharePoint to kick off the workflow.

Thanks,
Reken Liu

September 2nd, 2015 3:06am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics