Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Building Everything on Serverless

Sponsored · Ship Features Fearlessly Turn features on and off without deploys. Used by thousands of Ruby developers.
Avatar for Noah Bass Noah Bass
January 17, 2019

Building Everything on Serverless

Serverless is a form of cloud computing that’s changing the way software is delivered. The talk introduces key characteristics of serverless and serverless apps, how serverless compute works, and then dives into a live demo.

Video: https://www.youtube.com/watch?v=BRFd-PHyu7g&t=324s

Avatar for Noah Bass

Noah Bass

January 17, 2019
Tweet

More Decks by Noah Bass

Other Decks in Technology

Transcript

  1. @n_bass Cloud App / Hobby Projects Enter Serverless + Serverless

    Compute Examples Under the Hood AWS Lambda Serverless Framework Live Demo
  2. @n_bass Your Code! Virtual Machine (or maybe PaaS) ? Your

    Code! Database/Datastore Logs Cron HTTP/S SSH
  3. @n_bass HTTP API for Web/Mobile App HTTPS Trigger Event Your

    Code! Function Database/ Datastore Services Other Functions, APIs APIs Logs, … Monitoring
  4. @n_bass HTTP API for Web/Mobile App HTTPS Call Event Your

    Code! Function Database/ Datastore Service
  5. @n_bass New Image/ Video in S3 Bucket Event Your Code!

    Function S3 Bucket Service Image and Video Resizing
  6. @n_bass Simple Function: Availability Event Instance Function HTTPS GET Instance

    Instance Instance https://martinfowler.com/articles/serverless.html
  7. @n_bass Pricing on AWS Lambda • $0.2 per 1 million

    requests • $0.00001667 per gb-sec
  8. @n_bass Sample Function 1 million requests
 800ms per request
 256mb

    (0.25gb) memory -> $0.2 -> 1M * 0.8sec -> 0.8M sec -> 0.8M sec * 0.25gb = 200,000 gb-sec
 200,000 * $0.00001667 = $3.34
 Total = $0.2 + $3.34 = $3.54/month
  9. @n_bass Scheduled Event: Weather Report Scheduled Event (1d) Event Our

    Code! Get data, then send email Function darksky.net API API AWS SES API
  10. @n_bass Resources • serverless.com • serverless.com/framework/docs/providers/aws/guide/quick-start/ • aws.amazon.com/lambda • aws.amazon.com/free

    • cloud.google.com/free • github.com/serverless/examples • github.com/anaibol/awesome-serverless • martinfowler.com/articles/serverless.html • www.youtube.com/watch?v=Y6B3Eqlj9Fw • github.com/openfaas/faas