Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Using the Event Gateway To Build Multi-Cloud Serverless Applications - JeffConf Hamburg 2018

1,619 views

Published on

How the serverless.com Event Gateway (https://serverless.com/event-gateway/) helps to build multi-cloud serverless applications.

Published in: Technology
  • Be the first to comment

Using the Event Gateway To Build Multi-Cloud Serverless Applications - JeffConf Hamburg 2018

  1. 1. Using the Event Gateway to build serverless multi-cloud applications
  2. 2. philipp@serverless.com @pmmuens Philipp Müns Software Engineer, Serverless Inc.
  3. 3. architectures serverless
  4. 4. http://theburningmonk.com/2016/12/yubls-road-to-serverless-architecture-part-1/
  5. 5. # serverless.yml service: name: users description: Users CRUD service provider: name: aws runtime: nodejs6.10 stage: prod region: us-east-1 functions: register: handler: users.register events: - http: path: /users method: POST
  6. 6. Use Cases ● Web, mobile, IoT backends ● Form processing ● Auth ● DevOps automation ● Stream processing ● Chatbots ● Voice apps ● GraphQL API ● ETL ● CRON jobs ● Webhooks ● Dynamic HTML ...
  7. 7. Server-Less == Service-Full
  8. 8. Going multi-cloud AWS Azure Google IBM On-Prem FaaS FaaS FaaS FaaS FaaS Business Problem
  9. 9. at a large scale is still hard serverless
  10. 10. The highly productive event router for FaaS Event Gateway
  11. 11. ● “Realtime data-flow engine” (L7 Proxy) ● Events (data) → Functions (serverless compute) ● API Gateway & Pub/Sub ● Run FaaS on any provider → Cross-cloud applications ● Extensible through middlewares and plugins ● Hosted version / On-Prem What is the Event Gateway?
  12. 12. AWS Lambda Azure Functions Google Cloud Functions Event Event Gateway On-Prem FaaS...
  13. 13. Goals ● Express all data as events ● React to any event, with any FaaS, in any location ● Be flexible, develop fast ● Accommodate many use-cases ● Decouple logic ● Decouple teams
  14. 14. Express all data as events ● Receives data via HTTP and interprets it as an event ● Ingests custom event schemas ● Ingests HTTP requests as events ● Emits logs, metrics & errors as events Data
  15. 15. ● Any event ● Supports major FaaS providers ● Discovery ● Composition ● Communication React to any event, with any FaaS, in any location AWS Lambda Azure Functions Google Cloud Functions
  16. 16. Be flexible, accommodate many use-cases
  17. 17. Be flexible, accommodate many use-cases Pub/Sub HTTP request with special headers Request body is converted to an event
  18. 18. Be flexible, accommodate many use-cases Pub/Sub HTTP request with special headers Request body is converted to an event API Gateway HTTP request Request is converted to an HTTP event
  19. 19. Be flexible, accommodate many use-cases Pub/Sub HTTP request with special headers Request body is converted to an event API Gateway HTTP request Request is converted to an HTTP event Webhooks HTTP request from a supported integration Event Gateway knows what to do
  20. 20. Decouple logic, decouple teams App Functions Marketing Functions HR Functions Event ● FaaS decouples logic ● Event-driven design decouples teams
  21. 21. an example event gateway
  22. 22. An example google-hello aws-hello
  23. 23. An example curl --request POST --url http://localhost:4001/v1/functions --header 'content-type: application/json' --data '{ "functionId": "aws-hello", "provider":{ "type": "awslambda", "arn": "arn:aws:lambda:::function:aws-hello", "region": "us-east-1" } }' google-hello aws-hello
  24. 24. An example curl --request POST --url http://localhost:4001/v1/functions --header 'content-type: application/json' --data '{ "functionId": "google-hello", "provider":{ "type": "http", "url": "https://cloudfunctions.net/google-hello" } }' google-hello aws-hello
  25. 25. An example curl --request POST --url http://localhost:4001/v1/subscriptions --header 'content-type: application/json' --data '{ "functionId": "aws-hello", "event": "http", "path": "/aws-hello", "method": "GET" }' google-hello aws-hello
  26. 26. An example curl --request POST --url http://localhost:4001/v1/subscriptions --header 'content-type: application/json' --data '{ "functionId": "google-hello", "event": "google.hello", "path": "/google-hello" }' google-hello aws-hello
  27. 27. An example curl http://localhost:4000/aws-hello google-hello aws-hello
  28. 28. An example curl --request POST --url http://localhost:4000 --header 'content-type: application/json' --header 'event: google.hello' --data '{ "firstName": "John", "lastName": "Doe" }' google-hello aws-hello
  29. 29. old architecture serverless
  30. 30. FaaS (single provider) Workflows (e.g. AWS StepFunctions) Streaming Data (e.g. AWS Kinesis) Pub/Sub (e.g. AWS SNS) API Gateway (e.g. AWS API Gateway)
  31. 31. new architecture serverless
  32. 32. FaaS (multi cloud / on-prem) Event Gateway
  33. 33. how do I get started? Event Gateway
  34. 34. How do I get started? ● Product page → https://serverless.com/event-gateway ● GitHub repository → https://github.com/serverless/event-gateway ● Hosted version → https://serverless.com/event-gateway/enterprise ● Example application → https://github.com/serverless/event-gateway-example ● Workshop / Tutorial → https://github.com/serverless/event-gateway-workshop
  35. 35. AWS Lambda Azure Functions Google Cloud Functions Pub/SubAPI Endpoints Webhooks Event Gateway
  36. 36. maciej@serverless.com @mthenw Maciej Winnicki Event Gateway Architect
  37. 37. philipp@serverless.com @pmmuens Philipp Müns Software Engineer, Serverless Inc.

×