Book Image

Advanced Serverless Architectures with Microsoft Azure

By : Daniel Bass
Book Image

Advanced Serverless Architectures with Microsoft Azure

By: Daniel Bass

Overview of this book

Advanced Serverless Architectures with Microsoft Azure redefines your experience of designing serverless systems. It shows you how to tackle challenges of varying levels, not just the straightforward ones. You'll be learning how to deliver features quickly by building systems, which retain the scalability and benefits of serverless. You'll begin your journey by learning how to build a simple, completely serverless application. Then, you'll build a highly scalable solution using a queue, load messages onto the queue, and read them asynchronously. To boost your knowledge further, the book also features durable functions and ways to use them to solve errors in a complex system. You'll then learn about security by building a security solution from serverless components. Next, you’ll gain an understanding of observability and ways to leverage application insights to bring you performance benefits. As you approach the concluding chapters, you’ll explore chaos engineering and the benefits of resilience, by actively switching off a few of the functions within a complex system, submitting a request, and observing the resulting behavior. By the end of this book, you will have developed the skills you need to build and maintain increasingly complex systems that match evolving platform requirements.
Table of Contents (8 chapters)

Interacting with Humans in Azure Durable Functions


Humans tend to be unpredictable and asynchronous in completing a task compared to a computing service. Consider the comparison between a message arriving on a queue for an Azure Function and a message arriving on a phone for a human. It is fairly certain that the Azure Function will complete that operation almost immediately, whereas the human is likely to have a random amount of delay as they get occupied with other work.

If we are trying to complete an order workflow while depending on human input (for example, authorizing the order or packing the shipping crate), then we are creating a set of distributed transactions. The general name for this is a "Saga". There are two broad approaches to working with this:

  • Orchestration: This refers to having a long-running process that requires the first task to be completed, and then the second, and so on.

  • Choreography: In this approach, each individual microservice handles a task and publishes an...