Partager via


SharePoint Designer 2013 Workflow Deployment Issue

In SharePoint Designer 2013 when you create and deploy a workflow to a SharePoint site, you might get this error;

Microsoft.Workflow.Client.ActivityValidationException: Workflow XAML failed validation due to the following errors:

Cannot set unknown member 'CheckInItem.ItemId'. HTTP headers received from the server - ActivityId: 0a36dc6a-c872-41c9-8302-310378bfc1de. NodeId: 2013-SP. Scope: /SharePoint/default/7bf81cf4-ef48-4507-a0b5-53f948d26fd0/b44b51c4-8b55-4cfb-993f-66f6f873bafa. Client ActivityId : ea960b9c-dd02-5067-249a-2f0446fce574. ---> System.Net.WebException: The remote server returned an error:

This failure could happen if the SharePoint sites are not registered properly with MTW which is the Workflow Manager engine service external to SharePoint that stores and runs the 2013 workflows you publish from SharePoint Designer. Make sure that you have configured the SharePoint host to use workflow service using Register-SPWorkflowService,

For HTTPS site

Register-SPWorkflowService -SPSite 'https://myhost/mysite' -WorkflowHostUri 'https://WorkFlowServer.domain.com:12290' -AllowOAuthHttp –Force

For HTTP site

Register-SPWorkflowService -SPSite 'https://myhost/mysite'  -WorkflowHostUri 'https://WorkFlowServer.domain.com:12291' -AllowOAuthHttp –Force

 

Important: You will have to Re-Register after installing March or any later update (2013).  

 

Register-SPWorkflowService FAQs:

Q: What does the Register-SPWorkflowService cmdlet actually do and what should I know about it?

A: The Register-SPWorkflowService cmdlet creates a Workflow Service Application and associated Service Application Proxy which connects the SharePoint farm with Workflow Manager. The cmdlet automatically adds the Workflow Service Application Proxy to the Default proxy group in SharePoint. If you are using a custom proxy group then you will need to add the Workflow Service Application Proxy to the custom group manually using either the Central Administration interface or the Add-SPServiceApplicationProxyGroupMember cmdlet.

Q: How many times should I run the Register-SPWorkflowService cmdlet?

A: The Workflow Service Application is farm wide and should only be run once. In other words, a SharePoint farm can only have one workflow connection, in the form of a Workflow Service Application Proxy (SAP), to a Workflow Manager instance. The proxy is then used for all Web Applications throughout the SharePoint farm.

Q: What is the referenced SharePoint site in the Register-SPWorkflowService cmdlet used for? Should I plan which site to use when running the cmdlet?

A: The referenced SharePoint site in the cmdlet is only to let the cmdlet know how to reference the SharePoint farm. Once the cmdlet has been run the SharePoint site referenced in the Register-SPWorkflowService cmdlet is not important. You can use any current site in the SharePoint farm to run the Register-SPWorkflowService cmdlet.

Q: If I add a new Web Application in SharePoint do I need to re-run the Register-SPWorkflowService cmdlet?

A: No, the Register-SPWorkflowService cmdlet should only be run once for the entire SharePoint farm. Once a SharePoint farm is associated with Workflow Manager the cmdlet does not need to be run again unless you are restoring SharePoint from a backup.

Comments

  • Anonymous
    October 14, 2014
    I need to re-register WF Servive and I had installed WFM on 3 servers do I need to do re-register to each of the server that have WFM installed?Thanks for your respondSwanl
  • Anonymous
    November 08, 2014
    I have installed WF manager perfectly and workflow is active now.But when i go to manage service application, Workflow service application is missing.. but im able to see Workflow service application Proxy... is it  fine? If you have any idea, can you please show some light.Thanks
  • Anonymous
    January 21, 2015
    Thanks alot. This is what I needed exactly
  • Anonymous
    April 13, 2015
    The comment has been removed