Toggle mobile navigation

Toggle search

Close search

Developing Workflows in SharePoint 2013, Office 365 and SharePoint Online “From the Consulting Trenches”

Posted by Errin O'Connor on Mar, 13, 2015 07:03

Workflow Development “From the Consulting Trenches”

There has been a complete update to SharePoint 2013’s workflow capabilities and overall workflow architecture, as shown in image below, with new features as well as the underlying workflow engine itself receiving a major overhaul. In this post, EPC Group’s SharePoint and Office 365 hybrid development team will walk you through new best practices and strategies regarding workflow development.

The workflows in SharePoint 2013 run within Workflow Manager by services, processes and logic received from SharePoint 2013. This means these processes moved to Workflow Manager no longer have to run in the SharePoint 2013 content farm and can utilize separate server resources and is decoupled from SharePoint to also support other platforms.

Some of the driving factors of these changes were around being able to provide a workflow solution to SharePoint 2013 users that would be able to function in an independent manner and bypass any possible performance or scalability limits of SharePoint with on-premisescloud, and hybrid cloud in mind.

Workflow Manager has a new infrastructure, built on Windows Workflow Foundation 4.5 (WF 4.5), and is a fully declarative authoring environment that enables your organization’s information workers the ability to use tools such SharePoint Designer 2013 and Visio 2013 to ensure the creation of workflows in a very visual and “swim lane” diagram type manner, as shown in image below.

There are a new set of Visual Studio 2013 workflow project templates for developers to craft very complex workflows with custom actions and capabilities to provide enterprise-level workflows to the masses.

It’s important to note that Workflow Manager is a separate download and must be configured to communicate with the SharePoint Server 2013 farm.

Note: InfoPath also supports elements of SharePoint 2013 workflow but with Microsoft phasing InfoPath EPC Group would not recommend using InfoPath for this or any other custom development requirement in SharePoint.

To ensure a seamless experience across both on-premises and cloud-based environments, Workflow Manager integrates with the new SharePoint 2013 app model which enables workflows to reside in SharePoint 2013,Office 365SharePoint Online and Windows Azure.

The integration with the SharePoint 2013 app model allows organizations to use the APIs, web services, and design templates available within this new technology release. This has provided developers the ability to create “workflow specific apps” for the automation of very common manual processes within the organization in which EPC Group has seen provide an instant boost to overall SharePoint user adoption.

If your organization has legacy SharePoint 2010 workflows that need to be utilized within the SharePoint 2013, you can look into using the SharePoint workflow Interop.

This feature is a “bridge” between the two platform which may meet your needs and save you from having to redesign a workflow that may be able to rely on this new feature.

Workflow Manager and New Workflow Related Terminology

Workflow Manager, build on WF 4.5, allows for workflows to be extended via web services (REST base) and is multi-tenant capable which is key to the ability to service not only SharePoint 2013 but also Office 365,SharePoint Online and Windows Azure. The Windows Azure service bus, as shown in the image below, provides for the hosted and widely available infrastructure to allow for the massive communication elements required for workflows that have large-scale event distribution and service publishing. The service bus provides for the connectivity to connectivity and available options for Windows Communication Foundation (WCF) and other service endpoints.

The image below shows a high-level overview a workflow that is processing and connecting to external locations.

The image below shows an overview of the massive communication elements and large-scale event capabilities of SharePoint 2013 workflows.

There are a lot of specific technical terms that are used with the new Workflow Manager and the new overall architecture of SharePoint 2013 workflows that you will need to understand as they will come up in both technical conversations with IT as well as with the business and they can become a bit confusing and sometimes seem to overlap each other.

The following provides for a list of key business and technical features in Workflow Manager as detailed below:

■  Workflows are fully declarative

■  Allow for high density and multi-tenancy

■  Provide for workflow artifact management

■  Allows for tracking and monitoring of workflows and related events

■  Provides for instance management

■  Provides for expressive workflows

■  Enables a visual designer to structure a workflow via Visio 2013 and/or SharePoint Designer 2013

Understanding Custom Actions and Activities in Workflows

Custom workflow actions are reusable workflow step that run within Workflow Manager via the SharePoint REST API and are compatible with Visual Studio 2013 as well as SharePoint Designer 2013. They are used at different levels within a “copy,” department or functional unit for interacting with the Workflow Manager. These “wrapper objects” encase the underlying activities in a format that can be modified via SharePoint Designer.

Custom workflow activities are “objects” of custom code that handle the method calls to the underlying APIs and web services that drive workflow behaviors and allow for the inclusion of business logic in code.

SharePoint 2013, Office 365, SharePoint Online and Windows Azure Application Development “From the Consulting Trenches”

This is the second in a series of blog posts by EPC Group on SharePoint 2013, Office 365, SharePoint Online and Microsoft Azure development strategies and best practices “from the consulting trenches.”