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

Serverless—less server?

Serverless—less server?

Michael Hausenblas

September 02, 2016
Tweet

More Decks by Michael Hausenblas

Other Decks in Technology

Transcript

  1. © 2016 Mesosphere, Inc. All Rights Reserved. SERVERLESS- LESS SERVER?

    1 Michael Hausenblas | SoftwareCircus, Amsterdam | 2016-09-02
  2. © 2016 Mesosphere, Inc. All Rights Reserved. sys admin appops

    developer architect QA/test engineer data engineer/scientist
  3. © 2016 Mesosphere, Inc. All Rights Reserved. BUILDING AND RELEASING

    APPS 4 dev server server VM dev dev dev ops ops ops ops container VM server VM VM container container container container ?
  4. © 2016 Mesosphere, Inc. All Rights Reserved. A SPECTRUM OF

    COMPUTE STYLES 5 serverless AWS Lambda, IFTTT function PaaS Heroku,
 GAE objects µS Docker +
 Marathon/ Kubernetes container monolith traditional
 3 tier app machine
  5. © 2016 Mesosphere, Inc. All Rights Reserved. HOW FAST CAN

    A FEATURE BE DEPLOYED? 6 serverless PaaS µS monolith agility
  6. © 2016 Mesosphere, Inc. All Rights Reserved. WHAT IS THE

    PROVISIONING EFFORT? 7 maintenance serverless PaaS µS monolith
  7. © 2016 Mesosphere, Inc. All Rights Reserved. WHAT ARE THE

    COSTS? 8 cost/unit serverless PaaS µS monolith
  8. © 2016 Mesosphere, Inc. All Rights Reserved. CONCEPT 10 •

    unit of compute: a function • dynamically allocated resources for event-driven function execution • high-level components: triggers, management, integrations triggers t integrations f management UI, CLI, API
  9. © 2016 Mesosphere, Inc. All Rights Reserved. A WORD ON

    MOTIVATION 11 https://twitter.com/patrickdebois/status/734459440603275264
  10. © 2016 Mesosphere, Inc. All Rights Reserved. AZURE FUNCTIONS 13

    https://azure.microsoft.com/en-us/documentation/articles/functions-overview/
  11. © 2016 Mesosphere, Inc. All Rights Reserved. GOOGLE CLOUD FUNCTIONS

    14 https://cloud.google.com/functions/docs/
  12. © 2016 Mesosphere, Inc. All Rights Reserved. AND MANY MORE

    … 18 • http://nano-lambda.com • https://webtask.io • http://stackhut.com • http://www.open-lambda.org
  13. © 2016 Mesosphere, Inc. All Rights Reserved. ROLL YOUR OWN:

    FLOCK-OF-BIRDS 19 https://github.com/mhausenblas/fob client /api/gen /api/call/$fid /api/stats dispatcher drivers Python Node.js ... HTTP POST .py HTTP GET $fid $fid
  14. © 2016 Mesosphere, Inc. All Rights Reserved. APPLICATION AREAS 21

    • Infrastructure tasks, e.g. reacting to an event triggered from cloud storage • Mobile and IoT apps: process events such as a user check • Image processing, for examples to create preview versions of an image • Data processing, like simple ETL pipelines to pre-process datasets
  15. © 2016 Mesosphere, Inc. All Rights Reserved. USE CASE: IMAGE

    THUMBNAILS 22 https://aws.amazon.com/solutions/case-studies/the-seattle-times/
  16. © 2016 Mesosphere, Inc. All Rights Reserved. USE CASE: TELETEXT.IO

    23 https://medium.com/teletext-io-blog/a-serverless-architecture-with-zero-maintenance-and-infinite-scalability-b00c2ceb4c2b
  17. © 2016 Mesosphere, Inc. All Rights Reserved. USE CASE: CALCULATING

    LINEUPS FOR A FANTASY GAME 24 https://fmlnerd.com/2016/08/16/30k-page-views-for-0-21-a-serverless-story/
  18. © 2016 Mesosphere, Inc. All Rights Reserved. SOME MORE USE

    CASES … 25 • Migration of an email marketing tool for small business
 http://microapps.com/blog/serverless-framework/ • Continuous Deployments
 https://hackernoon.com/continuous-deployments-with-serverless-v0-5-c29138d6debf • Ticketing system
 https://blog.snap-ci.com/blog/2016/05/30/serverless-architecture-aws-lambda-dynamodb-applauze/ • iRobots IoT service
 http://www.slideshare.net/ServerlessConf/ben-kehoe-serverless-architecture-for-the-internet-of-things • Replacing cron jobs
 http://www.slideshare.net/AmazonWebServices/cmp407-lambda-as-cron-scheduling-invocations-in- aws-lambda • Fetch nearby Pokemon Go data
 https://github.com/jch254/pokego-serverless
  19. © 2016 Mesosphere, Inc. All Rights Reserved. CHALLENGES 27 •

    workload fit • developing functions • monitoring • stateful services • cultural and organizational issues
  20. © 2016 Mesosphere, Inc. All Rights Reserved. latency critical
 high

    frequency access latency tolerant
 high frequency access latency critical
 low frequency access latency tolerant
 low frequency access LATENCY VS. ACCESS FREQUENCY 28 access frequency latency sensitivity
  21. © 2016 Mesosphere, Inc. All Rights Reserved. DEVELOPING FUNCTIONS 29

    • local development? • testing • version control • what about many functions?
  22. © 2016 Mesosphere, Inc. All Rights Reserved. MONITORING 30 •

    troubleshooting • logging • alerting
  23. © 2016 Mesosphere, Inc. All Rights Reserved. 32 appops The

    person who writes an app is also the person responsible for operating the app in prod.
  24. © 2016 Mesosphere, Inc. All Rights Reserved. 33 It's not

    about provisioning, capacity planning, DR, etc.
 
 … this would be on the infrastructure team. appops
  25. © 2016 Mesosphere, Inc. All Rights Reserved. Q & A

    35 • @mhausenblas • mhausenblas.info • [email protected] https://dcos.io