Lambda

Fully-managed Function-as-a-Service!

Essentials

  • "Serverless" computing platform

    • There are servers, but we don't see them or concern ourselves with them.

  • Serverless means that you run code without provisioning or managing servers.

    • So if you want to run code, you don't have to spin up an EC2 instance and install software, you can just create a "Lambda function", drop code in, and execute it

  • Lambda allows you to configure the amount of resources (memory, CPU) available to your function

  • You pay only for the compute time necessary (to the millisecond)

  • By default, it is highly available, fault-tolerant, scalable, elastic, and cost efficient

  • Lambda integrates well with many other AWS services

  • Current support languages supported:

    • Node.js

    • Java

    • C#

    • Python

    • Go

    • Ruby (New)

    • Custom Runtimes!!! (Bash on the end, but now pretty much any language you want!)

Lambda vs. EC2

  • Generally you want to use Lambda when you want to run code that is in response to events such as:

    • Changes to S3 buckets

    • Updates to an Amazon DynamoDB table

    • Custom events generated by your application or devices

    • Kinesis Streams

Pricing & Costs

  • First 1M requests/month - FREE!

    • $0.20 per 1M requests/month after

  • First 400kkk GB-sec/month- FREE!

    • $16.67 per 1M GB-sec/month after

Implementation

  • Lambda includes handler functions built into samples in which you define the event, context and callback.

Last updated

Was this helpful?