Book Image

Building Serverless Applications with Python

Book Image

Building Serverless Applications with Python

Overview of this book

Serverless architectures allow you to build and run applications and services without having to manage the infrastructure. Many companies have adopted this architecture to save cost and improve scalability. This book will help you design serverless architectures for your applications with AWS and Python. The book is divided into three modules. The first module explains the fundamentals of serverless architecture and how AWS lambda functions work. In the next module, you will learn to build, release, and deploy your application to production. You will also learn to log and test your application. In the third module, we will take you through advanced topics such as building a serverless API for your application. You will also learn to troubleshoot and monitor your app and master AWS lambda programming concepts with API references. Moving on, you will also learn how to scale up serverless applications and handle distributed serverless systems in production. By the end of the book, you will be equipped with the knowledge required to build scalable and cost-efficient Python applications with a serverless framework.
Table of Contents (11 chapters)

Deploying a Lambda Function with SAM

So far, we have learned about Lambda functions and how to build them. We have learned that a Lambda function has a definite set of triggers that would trigger the function to carry out a particular task. The task is written as a Python module and the script is what we call a function. We have also learned about the different settings of Lambda functions, which include its core settings and also other settings, such as security and network.

There is also another alternative to creating and deploying Lambda functions, which is the AWS Serverless Application Model (AWS SAM). This format is based on the concept of infrastructure as code. This concept is inspired by AWS CloudFormation, which is a form of infrastructure as code.

We will be learning about AWS CloudFormation and using that knowledge to understand and build AWS SAM models for creating...