Microsoft Flow In 10 Days - Day Six - Flow Vs Logic Apps

Today, I will be covering the day 6 topic of my MS Flow series. If you have not checked out my previous posts about Microsoft Flow, I would recommend you to have a look at it. Links to the previous posts are given below.

What I am going to cover

I am planning to write a series on MS Flow on which I will cover most of the areas in it. This will be a 10 day series

A few points before moving to the topic:

Microsoft Flow is an online service that helps in connecting various apps and services. And those include Microsoft products like SharePoint, Dynamics, Excel, Power BI etc... and non-Microsoft services like Twitter, Facebook, MailChimp, etc...

Logic Apps

Today, I will be covering the topics on Microsoft Azure Logic Apps and the difference between logic Apps and our Microsoft Flow.

Logic Apps is one of the main pillars of the Microsoft’s cloud computing service - Microsoft Azure.

Logic Apps is a managed service that provides the “Lego blocks” of Azure serverless architecture that you can use to create, develop and deploy cloud-based integrations and workflows. The developer merely strings together off-the-shelf, ready-made components with as little effort as possible. The aim is to go from development to production in a few simple, reproducible steps.

By reading the above you might be thinking – “That’s what MS flow does!! So what’s the difference here?”.

Well, we will see that today.

First, we will see the similarities between these two. Flow and Logic Apps are both designer-first integration services that can create workflows. Both services integrate with various SaaS and enterprise applications.

Flow is built on top of Logic Apps. They share the same workflow designer and the same Connectors. So that means Flow is built on top of the Logic Apps.

If we see the diagram below, we can understand that.

  MS Flow

Logic apps serve as the basement architecture for this serverless connectors based service. And our MS Flow has embraced that architecture and has been built over it. So we can infer that every Flow developed can be done through Logic App also. All the examples thus far we have seen in MS Flow can be developed through Logic Apps also.

  MS Flow

Every MS Flow is a Logic App and not every Logic App is an MS Flow!! MS Flow is something like a subset of Logic Apps.

The differences between the two are - the other building blocks of Azure family, cannot be consumed in MS Flow, for Example Azure Functions, Azure Service bus etc. We will see this elaborately in the later point of this series.

There are some other differences between these two platforms which help in making the decision to prefer one over the other. I have these in perspective of development only. Other than this we have differences in pricing, security etc. We will see that in the last part of this series. 

Logic Apps

MS Flow

Intended for IT professionals, Developers

Business Users and mainly for SharePoint developers and Admins

Advanced Integrations

Not as much as Logic Apps

Can be developed in Browser

Browser and Mobile view

Logic apps are intended for developers also. To explain that, I am going to create a Logic App and explain from there.

Login to your Azure portal first - https://portal.azure.com

If you do not have an Azure Account, tyou can create a free trial - https://azure.microsoft.com/en-in/offers

Once we are logged into the portal, on the left panel we see all the Azure Resources. We have lots of Azure Resource materials in the C# corner if you want to explore each category.

 MS Flow 

In the middle of the screen, we have our Dashboard and the artifacts we create will be pinned here (optional).

Now we are going to create a Logic App.

Logic App Creation

To create a new Logic App, type “logic” in the search bar and select “Logic Apps” from the options shown below.

  MS Flow 

Now click on “Create Logic App” on the next screen.

 MS Flow

It opens up a panel sort of thing, where the details are entered for the new logic app. I am selecting my already created resource group here.

Once all are filled, click on Create button.

  MS Flow 

After a couple of minutes, if you refresh the page, we can see the below.

  MS Flow 

Click on the Logic App, it navigates to the templates page where we can select an already available trigger. (Same as the MS Flow functionality).

 MS Flow 

In the above screenshot, we can see, there are some triggers which are not part of the MS Flow (highlighted in Red).

Highlighted in green are the things which are common for MS Flow as well as Logic Apps.

Also, we can start from blank, (scroll down a bit) like how we do in MS Flow. If you need any clarifications, please refer to my previous articles (Links given above).

 MS Flow 

Click on this to start a new Logic App from Blank.

We get to see a screen that is very similar to the Flow’s screen.

 MS Flow 

In this, I am going to select SharePoint as the connector.

I am going to pass the address of my site and take “Leave Request” as my list, and I will get a screen like this.

 MS Flow 

We can see a difference in this when comparing this with MS flow. There will be an additional block “How often do you want to check for items?”

  MS Flow 
 
The same thing happens in Flow Block -
 
 MS Flow 

There is certainly a difference between these 2 systems.

So from this what we can infer is, when a new item is created in SharePoint,

  • MS Flow gets triggered by it.
  • But Logic App is not triggered during item creation, alternatively, it checks the SharePoint list in a timely manner to check whether a new item has entered the list or not. (This seems something like a webhook – we will see that another article)

 I am setting the time frequency for 5 seconds. And when a new item is created, I am sending the mail to the person who created it.

Same as in MS flow, we get the metadata panel on the right side when clicking inside any field.

 MS Flow 

Now we are going to test it after saving. This will be present at the top of the designer view of this logic app.

Click on Run to test it.

 MS Flow 

We will get the below screen once we click Run.

 MS Flow 

Once a new item is created in the list, we see the below notification on the right top corner of the screen.

 MS Flow 

Also, we can see the first step (item created trigger) has a  green tick. Then after a few seconds, we can see both steps are successful and the green tick is on both the steps.

 MS Flow 

So it has successfully run. So we can say that this is very similar to the MS flow environment with a few differences.

Now how do the developers come into the picture. There is a code view along with this Logic Apps architecture.

 MS Flow 

Click on the code view and you will see a huge JSON file. You can go through the JSON file and find all the settings we have done on the designer view of this Logic App.

If we do changes in the Code view and save it, it will still be reflecting in our logic app.

We can start from scratch and build a complete logic app in the code view.

Yes!!! This can be done easily using the Visual Studio IDE.

 MS Flow 
 MS Flow 

That’s how developers can do this in their own way.

These are some of the key features of Logic apps. Also, we have seen the similarities and differences between the two systems.

I will try to cover more of Azure and its components in another set of articles.

Thanks for reading. Let me know your comments below.


Similar Articles