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

The Serverless Cloud Integration Pattern

The Serverless Cloud Integration Pattern

Presented at ServerlessConf London 2016, with Dragos Dascalita Haut

4841b262608160b87e5e9766ee041a2a?s=128

Lars Trieloff

October 27, 2016
Tweet

More Decks by Lars Trieloff

Other Decks in Programming

Transcript

  1. The Serverless Cloud Integration Pattern

  2. None
  3. I want a film^H conference that starts with an earthquake^H

    evacuation and then works up to a climax.
  4. . ̴̴ Lars Trieloff ̴̴̴̴̴̴ Dragos Dascalita Haut . ̴

    @trieloff ̴̴̴̴ @ria_thinker
  5. None
  6. 3 Clouds

  7. 100+ Products

  8. Many acquisitions

  9. Diverse Technology Stack

  10. None
  11. Big Cloud Users

  12. Behind some of the biggest brands

  13. Question: how to make it all play together?

  14. Question: how to make it play with the rest of

    the world?
  15. Answer: let’s build a cool website

  16. None
  17. Just kidding

  18. Who is building integrations? Who is building apps with Adobe

    APIs? Who is building experiences using Adobe Products?
  19. Developers, Developers, Developers

  20. What Developers Want

  21. → Write Code → Deploy Code → Manage Servers

  22. → Write Code → Deploy Code → Manage Servers →

    Drink Beer
  23. → Write Code → Deploy Code → Manage Servers →

    Drink Beer
  24. Servers: can’t live with them, can’t live without them.

  25. Here is our 4-Step plan to serverlessness

  26. 1. Put Servers behind Glass

  27. None
  28. APIs

  29. API Gateway

  30. → Caching → Throttling → Authentication → Logging

  31. From dumb proxy to smart gateway

  32. → Hide yo monoliths → Establish API practices → Provide

    easy access
  33. → NGINX → OpenResty → Lua

  34. !" https://github.com/adobe-apiplatform/apigateway

  35. Establish API Best practices

  36. Establish API Best practices

  37. None
  38. 2. Contain your Applications

  39. None
  40. Containers

  41. Ethos → Standardized Container OS → Standardized CI/CD pipeline →

    Feature flags as a Service
  42. 3. Put Code on the Short Leash

  43. None
  44. Serverless Runtime

  45. Never trust a computer you can't throw out a window.

    — Steve Wozniak
  46. Never trust code you can’t terminate after one second. —

    Dragos Dascalita Haut
  47. Serverless Integrations → WebHooks++ → Low Latency → Low Maintenance

  48. Our needs → Untrusted Code → Extensibility + Context →

    Cloud Provider Independence
  49. None
  50. Are you guys serious about the delivery date? — John

    Pritchard, Director Engineering
  51. OpenWhisk !" https://github.com/openwhisk/openwhisk

  52. None
  53. http://bit.ly/apachewhisk

  54. 4. Wait for the call

  55. None
  56. Event Gateway

  57. Why Events? → Asynchronous Processing → Function Orchestration → Reliability

    & Scalability
  58. Demo Because everyone ♥ bots

  59. ┌───────────────────┐ ┌───────────────────┐ ┌───────────────────┐ │ │ │ │ │ │ │

    │ │ │ │ │ │ Alexa ! │──────────▶│ API Gateway " │──────────▶│ OpenWhisk # │ │ │ │ │ │ │ │ │ │ │ │ │ └───────────────────┘ └───────────────────┘ └───────────────────┘
  60. None
  61. Training Alexa ┌─────────────────┐ ┌─────────────────┐ │ │ │ │ │ │

    │ │ │ Intent │⾢─────────▶│ User Phrase │ │ │ │ │ │ │ │ │ └─────────────────┘ └─────────────────┘
  62. Training Alexa How many page views this month? { "intents":

    [ { "intent": "PageViews" } ] }
  63. Training Alexa How many {metric name} this month? { "intents":

    [ { "intent": “CustomView”, "slots": [ { "name":"MetricName", "type":"LIST_OF_METRICS" } ] } ] }
  64. Writing the Function Copy the code !" http://bit.ly/dragosdemo Add the

    function on the CLI wsk -i action create alexa alexa-demo.js
  65. None
  66. Why the gateway? Alexa Headers: SignatureCertChainUrl, Signature & … OpenWhisk

    expects: Authorization
  67. Signature !1 Authorization 1 not real magic

  68. None
  69. FIN (don’t forget to check out adobe.io)