Concurrency in Integra: Actions and Workflows

  • Posted on: 23 February 2015
  • By: David La Motta
There are two types of concurrency available in Integra today: at the workflow action level, and at the workflow level itself.  We'll examine both here and show you how you can use Integra to achieve concurrency in the most simple way possible.  

Example Workflow


The example in the image above is an oversimplification of the steps needed to backup SQL Server, MySQL and Exchange to the cloud; if you'd like a real example of application cloud-backup, there is another article that covers that.  For now, we are going to use the example in the image to drive the point of how easy it is to achieve concurrency in Integra, nothing more.

Concurrent Actions

Each block has a number associated with it; as such, you can think of it as a concurrent execution set in a workflow.  Broadly speaking, in order to do a cloud-backup using Integra we would quiesce the applications, take storage-level snapshots, unquiesce the applications, clone the data and use the cloned data to push to the cloud.  We will allow our imagination to believe that we are dealing with 3 different storage vendors: Nimble Storage, NetApp and Pure Storage.  Furthermore, we will say that our SQL Server data lives on Nimble Storage, MySQL data lives on NetApp, and that Exchange is sitting pretty on Pure Storage.

The image below shows what the steps looked like in an Integra workflow, should you have dragged and dropped each step and done nothing else.

Workflow Sequence Steps


At this point all of our workflow actions are configured to do the operations they are intended to, but there is one problem:  all of these steps will execute in sequence, which is not precisely what we set out to do.  So, this begs the question, what do we do in order to have blocks of steps execute at the same time?

The answer is simple.  Clicking on each Step cell allows you to edit the Step number.  Give that step the priority you'd like and hit the Enter key; that's it!

Steps Detail

 We will repeat the process for all of our workflow steps so that the result is the same as the opening image.

Workflow Parallel Steps

There is not much more to it.  We now have 5 blocks of steps that will execute in sequence; however, the steps in each block will execute in at the same time.  If you'd like to rearrange steps or change priorities, simply play with the step numbers until you achieve the desired sequence and / or concurrency.  Steps in each concurrent block are guaranteed to finish before the next step is executed; this means that all 1's will finish before the 2's execute, and so on.

Concurrent Workflows

If you think configuring concurrent workflow steps was simple, you may not believe running concurrent workflows could be simpler than that.  To illustrate the point, we will create 2 additional workflows.  The steps in those workflows are irrelevant.

Additional Workflows

When we switch over to the schedules tab, that is when things get interesting.  Lets single out the next statement in a paragraph by itself, if not I am afraid what we are about to say may come and go too quickly.

Every workflow which belongs to a schedule will be executed concurrently, irrespective of how the schedule is executed.  You may run the schedule by hand, or you may run the scheduled at different set times; the result is the same: any workflow that belongs to the schedule will be executed at the same time.

Parallel Workflows

Conclusion

We conceived concurrency as one of the core pieces of functionality in Integra when designing the platform's architecture.  In following our mantra of keeping things simple, we believe it will be hard to beat how easy concurrency is achieved in Integra.  Just remember that you have full control over workflow step priorities, and assigning the same step number to two or more steps will execute them at the same time.  Workflows in a schedule are executed concurrently by default; if you'd like to execute workflows in sequence, check out this section in the Integra User Guide which covers that topic thoroughly.

Happy automating!

--