Going serverless

Streaming Data with AWS Kinesis and Lambda

Maksim Pecherskiy

Data Engineer

Last chapter

PCXoZ.png

Streaming Data with AWS Kinesis and Lambda

vtceY.png

Streaming Data with AWS Kinesis and Lambda

Ln4Nq.png

Streaming Data with AWS Kinesis and Lambda

5JDPF.png

Streaming Data with AWS Kinesis and Lambda

iYVBt.png

Streaming Data with AWS Kinesis and Lambda

ahwx2.png

Streaming Data with AWS Kinesis and Lambda

Lambda

oKm7m.png

qBDP5.png

Streaming Data with AWS Kinesis and Lambda

Serverless

BDkHD.png

  • Servers managed by cloud provider
  • Pay per execution
  • Automatic scaling
  • Lower memory and exec time limits
  • Great for quick, targeted functions
  • Responding to an event with a callback

Servers (Traditional)

sy3ni.png

  • Servers managed by user
  • Pay per hour of running the machine
  • Manual scaling
  • Higher memory and exec time limits
  • Great for long running code executions
  • Training a machine learning model
Streaming Data with AWS Kinesis and Lambda

1. Trigger

2020-07-07_22-52.png

Streaming Data with AWS Kinesis and Lambda

2. Handler

2020-07-07_22-53.png

Streaming Data with AWS Kinesis and Lambda

3. Layer

2020-07-07_22-54.png

Streaming Data with AWS Kinesis and Lambda

4. Destination

2020-07-07_22-55.png

Streaming Data with AWS Kinesis and Lambda

Powerful combination

Data Transformation MF1mq.png

API oRmuU.png

Alerting Nm4UE.png

Alexa rYT3z.png

Streaming Data with AWS Kinesis and Lambda

Sample handler

import json

def lambda_handler(event, context):

return { 'statusCode': 200, 'body': json.dumps('Hello from Lambda!') }
Streaming Data with AWS Kinesis and Lambda

Review

UUmiG.png

Streaming Data with AWS Kinesis and Lambda

Review

Data Transformation

MF1mq.png

API

oRmuU.png

Alerting

Nm4UE.png

Alexa

rYT3z.png

Streaming Data with AWS Kinesis and Lambda

Review

Serverless

BDkHD.png

  • Responding to an event

Traditional

sy3ni.png

  • Training an ML model
Streaming Data with AWS Kinesis and Lambda

Review

1K8id.png

Streaming Data with AWS Kinesis and Lambda

Let's practice!

Streaming Data with AWS Kinesis and Lambda

Preparing Video For Download...