Maiores detalhes sobre o escopo do fluxo de trabalho:
"A scope is a named and securable container for Activities, Workflows, Instances, configuration and child Scopes.. It also provides a boundary for multi-tenancy and messaging (notifications). Scopes can be created and modified using the Workflow Client API. It is represented in the Client API by the T:Microsoft.Workflow.Client.ScopeInfo class."
Evento no log do SharePoint:
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Microsoft.Workflow.Client.ScopeNotFoundException: Scope '/SharePoint/default/<site collection GUID>/<subsite GUID>' was not found. HTTP headers received from the server - ActivityId: <GUID>. NodeId: <Server name>. Scope: /SharePoint/default/<site collection GUID>/<subsite GUID>. Client ActivityId : <GUID>. ---> System.Net.WebException: The remote server returned an error: (404) Not Found.
at Microsoft.Workflow.Common.AsyncResult.End[TAsyncResult](IAsyncResult result)
at Microsoft.Workflow.Client.HttpGetResponseAsyncResult`1.End(IAsyncResult result)
at Microsoft.Workflow.Client.ClientHelpers.SendRequest[T](HttpWebRequest request, T content) -
-- End of inner exception stack trace ---
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Microsoft.Workflow.Client.ScopeNotFoundException: Scope '/SharePoint/default/<site collection GUID>/<subsite GUID>' was not found. HTTP headers received from the server - ActivityId: <GUID>. NodeId: <Server name>. Scope: /SharePoint/default/<site collection GUID>/<subsite GUID>. Client ActivityId : <GUID>. ---> System.Net.WebException: The remote server returned an error: (404) Not Found.
at Microsoft.Workflow.Common.AsyncResult.End[TAsyncResult](IAsyncResult result)
at Microsoft.Workflow.Client.HttpGetResponseAsyncResult`1.End(IAsyncResult result)
at Microsoft.Workflow.Client.ClientHelpers.SendRequest[T](HttpWebRequest request, T content) -
-- End of inner exception stack trace ---
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Solução:
Execute os dois comandos abaixo para desabilitar e habilitar o feature oculto "WorkflowServiceStore" para forçar a cria do escopo, em seguida publique os fluxos de trabalhos.
1. Disable-SPFeature WorkflowServiceStore -Url <endereço do subsite>
2. Enable-SPFeature WorkflowServiceStore -Url <endereço do subsite>
2. Enable-SPFeature WorkflowServiceStore -Url <endereço do subsite>