2

I have a SharePoint 2013 workflow (let's call it LSR Status Workflow) that is associated with a list (called LSR List). When a user creates an item in the LSR List, it automatically starts the LSR Status Workflow. That is what I wanted, but sometimes I make changes to the workflow (via SharePoint designer) and then I would want to terminate the existing workflows that are running and restart them.

When I try to start a workflow for anyone other than a list item that I created, I get the following error:

Retrying last request. Next attempt scheduled in less than one minute. Details of last request: HTTP NotFound to https://publishing.web.company.com/sites/mysite/_vti_bin/client.svc/web/lists/getbyid(guid'1f844b8f-19aa-4587-bcc2-dfb7085f36b5')/Items(31) Correlation Id: 8efc5304-f0a3-90f6-8ece-6875bf811869 Instance Id: 60c83aae-5c25-4ee8-9c85-c64958ba701e

Then when the workflow is finally suspended after it keeps retrying, it reports the following error:

RequestorId: 8efc5304-f0a3-90f6-0000-000000000000. Details: An unhandled exception occurred during the execution of the workflow instance. Exception details: System.ApplicationException: HTTP 404 {"Transfer-Encoding":["chunked"],"X-SharePointHealthScore":["0"],"SPClientServiceRequestDuration":["36"],"SPRequestGuid":["8efc5304-f0a3-90f6-9bbd-d18d4d90af1b"],"request-id":["8efc5304-f0a3-90f6-9bbd-d18d4d90af1b"],"X-FRAME-OPTIONS":["SAMEORIGIN"],"MicrosoftSharePointTeamServices":["15.0.0.4551"],"X-Content-Type-Options":["nosniff"],"X-MS-InvokeApp":["1; RequireReadOnly"],"Cache-Control":["max-age=0, private"],"Date":["Tue, 10 Feb 2015 22:36:44 GMT"],"Set-Cookie":["BIGipServerpublishing-blv-80-pool=2825582466.20480.0000; path=/"],"Server":["Microsoft-IIS/7.5"],"X-AspNet-Version":["4.0.30319"],"X-Powered-By":["ASP.NET"]} at Microsoft.Activities.Hosting.Runtime.Subroutine.SubroutineChild.Execute(CodeActivityContext context) at System.Activities.CodeActivity.InternalExecute(ActivityInstance instance, ActivityExecutor executor, BookmarkManager bookmarkManager) at System.Activities.Runtime.ActivityExecutor.ExecuteActivityWorkItem.ExecuteBody(ActivityExecutor executor, BookmarkManager bookmarkManager, Location resultLocation)

If I created the list item, I can stop it and restart it without any problems, but this is not the case for list items created by someone else. What settings do I need to change so that I can start a workflow for a list item created by another user? I am the owner of the SharePoint site and am able to make changes to permissions if needed.

2

When you change existing structure of the workflow your old running workflows will fail at the time they rehydrate. This happens because the your old item's workflow definition is not match with the latest definition.

The option is you need to keep the old workflow and publish the workflow as new workflow. Then go to the list -> workflow settings and set no new instances for old workflow .

I have written a blog post about this. you can refer to it if you need more information .

http://sujeewa.com/2015/06/how-to-upgrade-the-visual-studio-sp2013-declarative-workflow/

2

I know i am late to answer this but this could happen if "Workflows can use app permissions" feature is not enabled on site

if an item is expected to be updated by multiple users and if it has workflow associated with it which perform some tasks on item update then we must have this feature enabled under site settings -> site features

1

Your account do not have permission to this list - guid'1f844b8f-19aa-4587-bcc2-dfb7085f36b5' or ItemId - 31.

Of course you can use "Workflows can use app permissions" feature and "AppStep" in SharePoint. Turning on this feature can be dangerous. It depends on who can create workflows and what are the permissions for the Workflow App. Workflow App in a simplified way it is a built-in add-id in SharePoint.

You have to remember that:

  1. context in workflow == the user (or add-in account) who starts the workflow (This is important with tasks, state-machine Workflows etc.).
  2. If you use AppStep container in your workflow, you have only WorkflowApp context for this container (not for all Workflow, only for this container).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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