kiko - Fotolia

Get up to speed on Azure's serverless functionality

With so many serverless tools on the market, it can be difficult to pick the right one. Review some of the features of Azure serverless options to help you choose.

Serverless computing is attractive because it offers flexibility and scalability -- without any server management. It also follows a consumption-based pricing model so enterprises only pay for what they use.

The major cloud providers have released a range of tools to meet the demand. While Microsoft wasn't first on the serverless scene, it quickly gained a foothold in the market thanks, in part, to its huge, established base of customers -- both large and small.

"The whole serverless discussion is being driven by developers. And when it comes to developer loyalty, I think Microsoft is doing a lot of important things [around tools and integrations]," said Jean Atelsek, an analyst at 451 Research.

Delve deeper into the serverless tools and services Azure has to offer.

Basics of Azure Functions

To compete with AWS Lambda, Microsoft released its own cloud-based serverless computing service, Azure Functions. This platform can be used to process data, build microservices and APIs, integrate systems and work with IoT deployments.

hosted serverless platform comparison
Top providers hosted serverless platform

Developers are gaining a greater say when it comes to choosing providers and tools to build modern applications. Azure Functions is an appealing option to them because it supports more programming languages -- including C#, Java and PowerShell -- than most of its competitors.

The other key features of the Azure serverless platform include:

  • Pay-per-use pricing
  • Bring your own dependencies
  • Integrated security
  • Simplified integration
  • Flexible development
  • Open source

To follow best practices with Azure Functions, make sure every function is stateless, idempotent, brief and only has a single purpose. Also, limit internal dependencies to decease runtimes.

Azure Functions has some similarities to AWS Lambda. For example, when it comes to handling persistent data, both services use stateless containers as the execution mechanism. However, Azure Functions can also store state between executions for Azure App Service applications that run on dedicated VMs.

When it comes to pricing, it can be difficult to compare the services from the major providers. Each pricing model has its own variations, with Azure being the most complex. For AWS, Azure and Google Cloud Functions, users are charged per execution, plus the time it takes to complete those tasks. For all three, execution time is measured in 100 ms increments, rounded up to the nearest increment. However, Azure also charges for memory consumption, which can make costs unpredictable.

Pick the right Azure serverless tool

Microsoft Azure offers a variety of serverless tools, but it's up to the user to decide which one fits their application demands based on how workload components will interact. Namely, users must pick between a pure Azure Functions application and a mixed app that combines serverless and conventional resources. The latter could require a different service, such as Logic Apps or Event Grid.

Users must plan the eventflow, also known as a serverless workflow. Here, they need to determine if the application is self-steering or orchestrated. A self-steering app uses its own logic to direct traffic, where one function receives events, then passes them to the appropriate function for handling. One Azure serverless feature, Function Proxies, works well in this model because it enables users to break up large APIs into microservices.

With orchestrated applications, some other aspect defines event-to-process relationships and sequencing. Users can choose between Logic Apps and Event Grid for their orchestration framework. Use Logic Apps to visually create and orchestrate workflows, as well as handle integration tasks. It is best suited for transaction processing that's created completely as functions.

Use Event Grid, which enables developers to build apps with event-based architectures, for apps that require combined orchestration of serverless and conventional components. These components should not be directly connected; instead, use queues and signals.

Azure API Management consumption tier

To meet the serverless demand and the growing number of use cases, Azure expanded its API pricing structure to include an option that moves away from the traditional hosting approach where services depend on permanence. Azure API Management consumption tier is well-suited for numerous applications, including those that are implemented with Azure services like Functions and Logic Apps.

Unlike the Development, Standard and Premium options, the consumption tier works on a pay-per-execution basis. Additionally, it has autoscaling and high availability capabilities. Another feature that helps it stand apart from other tiers is its emphasis on long-running services and externalized caching.

Azure API pricing tiers
Compare API pricing tiers

It should be noted, there are some features this resource-focused tier doesn't have, partly due to technical limitations. Some of the missing elements include:

  • Security learning features
  • Developer portal
  • Built-in analytics
  • Disaster recovery
  • Logging and metrics

Before you choose a pricing tier, review what you need from your API and see if the benefits outweigh the drawbacks.

Next Steps

5 Azure Functions logging best practices

Create a private endpoint to secure Azure Functions apps

Dig Deeper on Cloud provider platforms and tools