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

design for cloud - jax 2012

design for cloud - jax 2012

Mathias Meyer

April 18, 2012
Tweet

More Decks by Mathias Meyer

Other Decks in Programming

Transcript

  1. design for cloud
    mathias meyer, jax 2012

    View full-size slide

  2. Me
    — infrastructure
    — code
    — databases
    @roidrage
    www.paperplanes.de

    View full-size slide

  3. amazon web services

    View full-size slide

  4. on-demand computing

    View full-size slide

  5. pay as you go

    View full-size slide

  6. multiple regions

    View full-size slide

  7. multiple datacenters

    View full-size slide

  8. high cpu
    vs.
    high memory

    View full-size slide

  9. elastic block store

    View full-size slide

  10. more aws products
    s3
    cloudfront
    cloudformation
    cloudwatch
    rds
    auto scaling
    simpledb
    route 53
    load balancing
    queue service
    notification service
    elastic mapreduce

    View full-size slide

  11. what’s scalarium?

    View full-size slide

  12. automates:
    setup
    configuration
    one-click deploy

    View full-size slide

  13. ...for ec2
    ...on ec2

    View full-size slide

  14. the dream:
    configure a cluster
    push a button
    boom!

    View full-size slide

  15. configuration
    + cookbooks/manifests
    + chef/puppet
    = configured cluster

    View full-size slide

  16. configuration:
    chef server
    rightscale
    json
    scalarium

    View full-size slide

  17. in the beginning...

    View full-size slide

  18. ec2 is not a traditional
    datacenter

    View full-size slide

  19. multi-tenant

    View full-size slide

  20. high chance of failure

    View full-size slide

  21. faulty instances

    View full-size slide

  22. datacenter outage

    View full-size slide

  23. network partition

    View full-size slide

  24. more instances
    =
    higher chance
    of failure

    View full-size slide

  25. don’t fear failure

    View full-size slide

  26. plan for failure

    View full-size slide

  27. test failure

    View full-size slide

  28. plan for recovery

    View full-size slide

  29. disaster recovery plan

    View full-size slide

  30. multi-datacenter
    deployments

    View full-size slide

  31. multi-region
    deployments

    View full-size slide

  32. relax consistency
    requirements

    View full-size slide

  33. keep data local

    View full-size slide

  34. keep data in memory

    View full-size slide

  35. cache is king

    View full-size slide

  36. use raids for ebs

    View full-size slide

  37. use local storage

    View full-size slide

  38. use bigger instances

    View full-size slide

  39. scalarium is
    ~monolithic

    View full-size slide

  40. cloud ≠ monolithic

    View full-size slide

  41. cloud ☠ centralized

    View full-size slide

  42. small, independent
    services

    View full-size slide

  43. self-contained

    View full-size slide

  44. independently
    deployable

    View full-size slide

  45. well defined apis

    View full-size slide

  46. http/json
    thrift
    protocol buffers

    View full-size slide

  47. sinatra
    dropwizard
    spark
    scalatra

    View full-size slide

  48. internal queues

    View full-size slide

  49. design for resilience

    View full-size slide

  50. “think about your
    software running.”
    theo schlossnagle, omniti

    View full-size slide

  51. understand your
    code’s breaking points

    View full-size slide

  52. isn’t all that what you
    do at large scale?

    View full-size slide

  53. cloud
    ==
    large scale

    View full-size slide

  54. scalarium today

    View full-size slide

  55. scalarium
    runs on
    scalarium

    View full-size slide

  56. lack of visibility

    View full-size slide

  57. don’t fall for
    service level
    agreements

    View full-size slide

  58. amazon only handles
    infrastructure

    View full-size slide

  59. how you build on it
    is up to you

    View full-size slide

  60. amazon.com
    is served off ec2

    View full-size slide