Superfilter AI
Course Description
Learn to use AWS Lambda in production using the serverless framework. Get started with AWS Lambda functions and then learn to test, debug and deploy then to build a real API powered by lambda functions.
This course and others like it are available as part of our Frontend Masters video subscription.
Preview
CloseCourse Details
Published: May 24, 2018
Topics
Learn Straight from the Experts Who Shape the Modern Web
Your Path to Senior Developer and Beyond
- 200+ In-depth courses
- 18 Learning Paths
- Industry Leading Experts
- Live Interactive Workshops
Table of Contents
Introduction
Section Duration: 27 minutes
- Scott Moss introduces Serverless with AWS course. Serverless architecture lets functions run as a service on AWS instead of running a full server.
- After discussing functions as a service run an independent method on a hosted server, Scott states that AWS Lamdas are AWS's functions as a service.
- Scott reviews serverless the framework as a tool that provides the power to manage and deploy serverless functions on any cloud hosting platform such as AWS, Azure, Google Cloud, and so on.
- After setting up with the Serverless framework and running lambda functions locally with the invoke -f command, Scott shows the path option that allows the passing in event data into functions.
- In this exercise, students create a lambda function and execute it locally on their respective machine. Then students pass in event data into the function.
- Scott walks through the solution to the Your First Lambda Exercise for creating a simple lambda function.
Lambda Events
Section Duration: 41 minutes
- Scott discusses executing lambdas synchronously and asynchronously.
- After saying that AWS has a growing list of event types that Lambdas can subscribe to, Scott demonstrates some of the common event types.
- Scott reviews the serverless framework, which creates an abstraction that is easier to work in conjunction with AWS CloudFormation. AWS CloudFormation allows for using different services across AWS with one configuration.
- Scott introduces AWS API Gateway, which allows for setting up routing for lambdas. The API Gateway routing allows for the creation of a full API on top of serverless functions. Scott takes questions from students.
- To get the same functionality of API Gateway to develop locally, Scott shows how to use the Serverless offline mode plugin.
- Scott takes questions from students about the tradeoffs and implementations of invoking other lambdas inside lambda functions.
- In this exercise, students configure routes for lambdas using the serverless YAML.
- Scott takes questions from students about best practices for keeping lambdas out of a cold state and if lambda functions are independent of each other.
- Scott walks through the solution to Lambda API Exercise by configuring the serverless YAML to build an API on top of lambda functions.
Deployment
Section Duration: 43 minutes
- Scott introduces steps to deploy lambda functions to AWS using the serverless deploy method.
- Scott walks through the tools in AWS to inspect and analyze the deployment of lambda functions. Scott takes questions from students.
- Scott reviews various settings on AWS for lambda functions including memory, timeouts, environment variables and more.
- Scott shows the monitoring dashboard as well as where to find the source code for lambda functions.
- In this exercise, students deploy and use lambdas on AWS using a serverless framework.
- Scott walks through the solution to the Deploy on AWS Exercise by showing how to deploy Lambdas to AWS. Scott takes questions from students.
Using Express
Section Duration: 31 minutes
- Scott uses the serverless framework to show the many ways to route requests from using multiple lambdas to multiple routes to using one lambda to one route.
- Scott illustrates how to take advantage of Express's routing capabilities and API within a lambda function to take control of routing vs. giving serverless control of the routing.
- Scott shows the lambda continues to run if there's an async task left. This behavior can be disabled this behavior using the context object.
- Scott takes questions from students about router options, express, and more.
- In this exercise, students convert an application to use Express's routing.
- After taking questions from students about using lambdas and Express, Scott reviews his solution and discusses
Testing
Section Duration: 8 minutes
- Scott discusses testing lambda functions using Jest and SuperTest.
- Scott sets up testing with SuperTest, which allows Express requests and retrieves results without having to start an Express server.
Wrapping Up
Section Duration: 16 minutes
- Scott reviews resources for working with AWS.
- Scott discusses globally distributed lambdas push traffic and using Lamda@Edge service to customize the content that CloudFront delivers.
- After taking questions from students about the cold start and "keeping lambdas warm," API gateways, and more, Scott wraps up Serverless with AWS course.
Learn Straight from the Experts Who Shape the Modern Web
- In-depth Courses
- Industry Leading Experts
- Learning Paths
- Live Interactive Workshops