Being a software practitioner and also a hardcore .NET developer, there are numerous amounts of times in the recent years when I came across the need of building a Workflow. Almost every single corporate organization in this world uses computer automation in one way or another, and when we talk about organization hierarchy and distribution of jobs with respect to roles, we clearly see a plethora of information moving within this hierarchy. As each piece of information may require certain amount of sharing and collaboration before finally arriving at the destination, the need of an information workflow within organization is inevitable. In this article, we will firstly see what organizational workflows are and how they fit into the organizational hierarchy and make information move within this hierarchy. Next, we will look at a couple of workflows that provide seamless integration with .NET, and provide SDKs to build workflows in .NET. Let’s delve ourselves into the exciting world of workflows.
Examining the Basics of Workflows
Firstly the question that adhere us is that of what is a workflow? Although there can be many definitions of that, but to keep it simple, I put it in this way: “A Workflow is a well defined sequence of steps in which information moves, and at a certain end point, these steps lead to a completion of this well govern workflow”. So we can think of a workflow as a set of steps and at each step we provide certain actions, that may or may not change the information itself but they certainly move it to the next step, and after passing through all these steps, the workflow ends and all set of actions on information are completed.
Now if you got a bit perplexed, let's take a moment to build a simple organizational hierarchy. Later I will show how to build an information workflow in contrast to the organizational hierarchy. Let’s consider a fictional financial organization namely "Stunner Corporation", they follow a simple Hierarchy in their organization (see figure 1.0). To start with, at the top, they have got a CEO (Chief Executive Officer), then comes HRD (Human Resources Head), next is Business Units (BU), and under each BU there can be multiple employees. Moreover the Roles are also associated with each designation. Although for our explanation I am keeping it simple, in a practical environment these roles with an association to the hierarchy can become the chief factor in designing the workflow.
Analyzing Organizational Needs for Workflow
Now that we have got a clear picture of Stunner Corporation’s hierarchy, the next step is to critically analyze their organizational needs; usually this step requires understanding the company chief's autonomous operations as these will later influence workflow design to a great extent. Now after analyzing the Stunner Corporation needs, the following list is prepared, which contains the tasks that can be mapped to a workflow to achieve information automation along with the description.
- Need for Automotive Vocational Approval System:- Every employee in Stunner Corporation when wants a leave or vocation, fills a form and give it to his/her Business Head (BH), the BH forwards this request to HR who decides either to approve it or reject it and inform the employee accordingly. Now the major obstacle the organization is facing is that of time constraint, as according to the company policy, every request for vocation must be completed in 3 days. But due to the large number employees this is not possible, as a result now they want to deploy a system which can replace manual work with computers.
- Need Employee Compliance System :- According to the company HR policy any employee can file a complaint, the complaint goes straight to HR where HR makes a decision and forwards it to the employee BU head who adds his comments on it and finally forwards it to the employee and also informs the CEO about the completion of the employee request. As their current compliance system consists completely of manual manipulation, it not only takes weeks before the compliance can finally be responded, it also leaves an open hole for information leak as some complaints are highly sensitive in nature. The company wants a complete computerized system to handle the compliance request along with information being moved securely.
Designing a Workflow
Now that we have enough knowledge about the organizational procedure, we move to next level to start designing the Workflow. Let us see some building blocks of Organizational Workflows. Later in this article, we will examine different Workflow Building tools available in the market, but the main point to note is that the major conceptual model or building blocks are quite similar if not same. So it’s important to learn the basics of workflow designing without associating with any specific vendor.
Let’s build a generic workflow design for a Vocational Approval System discussed in the previous section. First take a moment to build a list of steps that are potential workflow steps and define in a clear and concise manner what step to be performed. We must also identify the starting step and the final step(s). I made a simple table of steps and actions to be performed on each step. I also marked the steps as start, end and intermediate according to the nature of the step (see Table 1.0).
||Description /Action Performed|
|Submit Leave Request
||Employee fills and submits the request for leave/vocation.|
|Business Head processes request
||BU Head overviews the employee's leave application and adds his/her comments on it.|
|HR processes the application
||HR Manager overviews the leave application and either rejects or accepts the application, and the final result is emailed to the employee.|
As we now had a narrow down of each step concisely and clearly, we are ready to start building the workflow, but one thing is still left and that is the identification of the use of automation at each step. For example, company BU Head should get the vocational application if and only if the employee asking for leaves has enough amount of leaves left. Moreover the applicant credentials must be kept synchronized as once his/her leave is approved the automatic deduction from his/her leaves should be done. The crux of the matter is that we must look for either an existing system or build some new MIS System to facilitate the workflow. This is important as the workflow can itself maintain a bulk of information but organization level information must reside in a separate MIS. Infract in our scenario, the Stunner corporation facilitates a complete Database in Microsoft SQL Server that stores all organization wide knowledge base from an employee's complete credentials to daily reminders.
If you feel a bit lost, it's ok, just keep in mind that in corporate environments where you are going on a task to build a workflow, the chances are you will have to use their existing system and build your workflow as a participant and not an entire new system that requires their existing systems to change drastically. By the way for keeping the example simple, I am using a very simple database and we utilize it only for the information validation and updating purposes. Let's move back and try to put validation into action so that every step is synchronized with the Organization Knowledge Base.
Putting Information Validation Rules into Workflow
In the start of the workflow, we must handle the validation of each request. Let’s try to inject validation in our workflow (see Table 1.0 for workflow steps). The utmost validation check is of employee current leave balance, the system should reject a leave application if the employee current leave balance is less than what he is asking for. As for example it wouldn’t make any sense to continue with the workflow if an employee doesn’t have any leave(s) left. Although at this point a developer inclined reader might argue that why we even give an employee a chance if his/her leave balance is zero? The answer to this lies in the pillars of Organizational Rules. Usually an employee making leave requests are noted for logging purposes, and this can be used for various analyzing purposes in the future, so denial of request should only be done by a workflow and not at certain point of input by directly using the knowledge through the system even if it is available. Following are the business rules that we will inject into the workflow:
- The current number of leaves left for the employee making the request should be greater or equal of what he/she is demanding for.
- In case of absence of HR, the request should be got back to the employee with a clear mention of the reason for this delay.
Now let's sum it up into a sequence diagram (see figure 2.0).
As it's evident from figure 2.0 that an Organizational Workflow can get immensely complex, in our case we only interact with a database for getting the user's left over leaves, but in more practical scenarios, we may want to do much more interaction with the database. Moreover the interaction mode b/w the computer and human can take many forms including emails, SMS, voicemail etc. In the next section, we take a tour of Workflow software available in the market. The workflow software that I discuss in the later sections provide SDK and claim native support in .NET. But to be honest only one of them truly deserve to be stated as fully .NET integrated and that is K2.Net Workflow which is discussed in the next section.
A brief look into workflow software in the market
There are a bunch of workflows available in the market, but only a couple of them really serve the purpose, and only one of them is truly .NET complaint. Others provide a very cheap wrapper from .NET which leaves developers in the middle of nowhere. The following is a list of three Workflow solutions that are widely used and provide or states to provide full integration with .NET.
|Workflow Solution Name
||Excellent Workflow solution, fully supports .NET Framework, integration with Share Point Portal 2003, Info Path Forms to name a few.|
|Captaris TeamPlate Workflow
||Average Workflow solution, supports .NET Framework but quite buggy due to cheap COM wrapper. Integration with Share Point Portal 2003, MCMS 2002, InfoPath and Exchange 2003.|
|Ultimus Business Process Solution
||A widely used business process modeling solution which has workflow as one of its components. No direct integration with .NET but provides a way to interact with external components. Provides support for Share Point Portal Server 2003, InfoPath, Exchange, to name a few.|
In the next installment of this series, we will look into K2.NET workflow and its SDK, till then Happy Programming. If you have got any questions, please feel free to ask at my email: firstname.lastname@example.org.