reading-notes

this repo will contain my reading during the course .

View project on GitHub

Class 18 Reading: AWS: API, Dynamo, and Lambda

Review, Research, and Discussion

What are serverless functions?

single-purpose, programmatic functions that are hosted on managed infrastructure. These functions, which are invoked through the Internet, are hosted and maintained by cloud computing companies. The engineering teams within those companies ensure that the serverless functions have near-perfect uptime, redundant instances around the world, and scale to any incoming network request volume.

If you were to create a system that emulated Lambda functions, how would you do it?

You could use serverless functions or you could create a CL tool to locally run and remotely deploy your node.js applications

Describe how a CDN works

CDNs work through servers nearest to the website visitor respond to the request. The content delivery network copies the pages of a website to a network of servers that are spread out at geographically different locations, caching the contents of the page. When a user requests a webpage that is part of a content delivery network, the CDN will redirect the request from the originating site’s server to a server in the CDN that is closest to the user and deliver the cached content. CDNs will also communicate with the originating server to deliver any content that has not been previously cached. In turn, the speed is improved by distributing content closer to the website visitors by using a nearby CDN server, causing visitors to experience faster page loading times. In simpler terms, for example, instead of a user in London trying to access a server in LA, which can cause slower Internet speeds, the user would be redirected through a CDN that is geographically closest to them (London, Paris, Stockholm, etc). As of today, the majority of web traffic goes through through CDNs, including traffic from major sites like Facebook, Netflix, and Amazon.

Document the following vocab words

Serverless functions:

single-purpose, programmatic functions that are hosted on managed infrastructure. These functions, which are invoked through the Internet, are hosted and maintained by cloud computing companies. The engineering teams within those companies ensure that the serverless functions have near-perfect uptime, redundant instances around the world, and scale to any incoming network request volume.

Cloud Storage:

a cloud computing model that stores data on the Internet through a cloud computing provider who manages and operates data storage as a service. It’s delivered on demand with just-in-time capacity and costs, and eliminates buying and managing your own data storage infrastructure. This gives you agility, global scale and durability, with “anytime, anywhere” data access..

CDN:

Content Delivery Network (CDN) is a geographically distributed group of servers that work together to provide fast delivery of Internet content. A CDN allows for the fast transfer of data needed for loading Internet content including HTML pages, javascript files, stylesheets, images, and videos.

Preview

Which 3 things had you heard about previously and now have better clarity on?

CDN, AWS Lambda, DynamoDB

Which 3 things are you hoping to learn more about in the upcoming lecture/demo?

Using Sockets in AWS, CDNs, DynamoDB

What are you most excited about trying to implement or see how it works?

AWS API Gateway

Preparation Materials

Amazon API Gateway

“Amazon API Gateway is a managed service that allows developers to define the HTTP endpoints of a REST API or a WebSocket API and connect those endpoints with the corresponding backend business logic. It also handles authentication, access control, monitoring, and tracing of API requests”.

“API Gateway sits between the backend services of your API and your API’s users, handling the HTTP requests to your API endpoints and routing them to the correct backends. It provides a set of tools that help you manage your API definitions and the mappings between endpoints and their respective backend services. It can also generate API references from your definitions and make them available to your users as API documentation”

“API Gateway integrates with many other AWS services like AWS Lambda, AWS SNS, AWS IAM, and Cognito Identity Pools. These integrations allow for fully managed authentication and authorization layers, as well as detailed metrics and tracing for API requests”

Many AWS services support integration with Amazon API Gateway, including:

  1. AWS Lambda: run Lambda functions to generate HTTP API responses.
  2. AWS SNS: publish SNS notifications when an HTTP API endpoint is accessed.
  3. Amazon Cognito: provide authentication and authorization for your HTTP APIs.

API Types

  • RESTful APIs
  • WEBSOCKET APIs img

Dynamoose

“Dynamoose is a modeling tool for Amazon’s DynamoDB. Dynamoose is heavily inspired by Mongoose, which means if you are coming from Mongoose the syntax will be very familar”.

Key Features

  1. Type Safety.
  2. High level API.
  3. Easy to use syntax.
  4. Ability to transform data before saving documents.
  5. callback & promise support.

img

Resources

AWS API Gateway Overview

AWS API Gateway

AWS DynamoDB Guide

AWS DynamoDB

Dynamoose