Serverless Technology Choices in Azure
Tags: azure, serverless, cloud
Published: 2021-09-12 06:47:19

> Which Azure Serverless Technology is the best choice for your business requirements?

### Overview

The objective of this article is to understand the basics and help you to choose the best Azure Serverless Technology for a general set of business requirements.  
  
This is assuming the users who reading this article have some basic knowledge on workflow, orchestration, and application programming. If not, I would suggest those to read more on said foundation topics before you jump into this article. :)  

### What is Serverless Computing?

Serverless computing is a cloud-hosted execution environment with a single or group of servers that runs your code, but abstracts the underlying hosting environment. The main concept is that we are not responsible for the infrastructure or the maintenance of the server. And we don’t have to worry about the outages or increase in demand during peak instances situations like the holidays or for black friday season ;) . The cloud provider takes care of maintenance, scalability, and everything else for you.  

> You just create an instance of the service and add your code in any desired language. That’s it!

Today we are going to see the two most popular and commonly used Azure Serverless technologies: Azure Functions and Azure Logic Apps.  

### Azure Functions

With the Azure Functions service, you can host a single method or function by using a popular programming language in the cloud that runs in response to an event. An example of an event might be an HTTP request, a new message on a queue, or a message on a timer.  
  
Functions can be written in many common programming languages, such as C#, Python, JavaScript, Typescript, Java, and PowerShell.  

#### Key Features

-   Scales automatically
-   Charges are applied only when the function is triggered
-   It is the best choice when demands are variable
-   Perform orchestration tasks using extension called Durable functions

### Azure Logic Apps

Logic Apps is a low-code/no-code development platform hosted as a cloud service. This service helps you automate and orchestrate tasks, business processes, and workflows when you need to integrate apps, data, systems, and services across enterprises or organizations  
  
We build an app by linking triggers to actions with connectors.  

> A  **trigger**  is an event (such as a timer) that causes an app to execute.  
>   
> An  **action**  is a task or step that can execute. (Available in different programming languages)

To build enterprise integration solutions with Azure Logic Apps, you can choose from a growing gallery of over 200 connectors. The gallery includes services such as Salesforce, SAP, Oracle DB, and file shares.  

#### Differences

[![Difference between Azure Functions and Azure Logic Apps](https://1.bp.blogspot.com/-skwFKbML25A/YSce71oKY7I/AAAAAAAAAKk/H_HMbfwKtGMMGNyOKaWdAMehpMSPa6OXQCLcBGAsYHQ/w640-h480/Green%2Band%2BBlack%2BCorporate%2BComparison%2BChart.png)](https://1.bp.blogspot.com/-skwFKbML25A/YSce71oKY7I/AAAAAAAAAKk/H_HMbfwKtGMMGNyOKaWdAMehpMSPa6OXQCLcBGAsYHQ/w640-h480/Green%2Band%2BBlack%2BCorporate%2BComparison%2BChart.png)

  
  

### Example Use Cases

#### When to choose Azure Functions

Code-based, you write and test the code. Will be able to debug without involving or provisions test resources in the cloud.  

-   If you have your code / logic / automated tasks already ready in your desired language, it is easy to just put the code in Azure Functions than to create it from scratch using Azure logic apps
-   If you need to perform some complex logic or specialized data parting, Azure Functions is the best since you have full control of the code and visualizing performing complex logic workflows is tough in Azure Logic Apps

#### When to choose Azure Logic Apps

GUI based. Preferable if we don’t want to get involved with developer resources and instead want to use GUI. Best suited for integration since lots of connectors are available out of the box.  

-   If we need to perform more orchestration tasks from different APIs, go for Azure Logic Apps.
-   If we need a visual workflow, Azure Logic Apps is the best choice

Combination of both is also a best choice for large scale enterprise cloud environments.

### Conclusion

In this article, we have just covered the high level overview and the differences between Azure Functions and Azure Logic Apps. Please go through the official Microsoft documentation cited in Reference section for further learning.

### References
https://docs.microsoft.com/en-us/learn/modules/serverless-fundamentals/

https://docs.microsoft.com/en-us/azure/azure-functions/functions-compare-logic-apps-ms-flow-webjobs

### Thanks for reading this post! 

I hope this article is informative and helpful in some way. If it is, please like and share this article. 

Happy learning!