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.

Service Mesh and Serverless Chatbots with Linkerd, K8s and OpenFaaS

This session will present the different challenges for telco companies when they deploy support chatbots for clients, this is based on a real experience of working with chatbots in a
telco company Telefónica based on Guatemala and some countries in Central America.
Presentado por Sergio Méndez en SG Virtual Conference 2020

  • Be the first to comment

  • Be the first to like this

Service Mesh and Serverless Chatbots with Linkerd, K8s and OpenFaaS

  1. 1. Service Mesh and Serverless Chatbots with Linkerd, K8s and OpenFaaS Sergio Méndez Unidos compartiendo y aprendiendo #SGVirtual
  2. 2. About me ● Operating Systems Professor ● Entrepreneur(curzona.com) ● Cloud Native enthusiast ● DevOps Consultor ● (Cloud-Native)+GT Meetup Organizer Sergio Méndez
  3. 3. Service Mesh and Serverless Chatbots with Linkerd, K8s and OpenFaaS
  4. 4. IT Infrastructure Evolution
  5. 5. Ref: Tal, L. (2019). Serverless Security. O’Reilly Media.
  6. 6. Monolith Containers Orchestrators Serverless Ref: Tal, L. (2019). Serverless Security. O’Reilly Media.
  7. 7. Ref: https://blogs.gartner.com/tony-iams/containers-serverless-computing-pave-way-cloud-native-infrastructure/
  8. 8. Basic concepts
  9. 9. #1 Cloud Native Cloud-native is an approach to building and running applications that exploits the advantages of the cloud computing model. Ref: https://tanzu.vmware.com/de/cloud-native
  10. 10. #2 Cloud Native Cloud native technologies empower organizations to build and run scalable applications in modern, dynamic environments such as public, private, and hybrid clouds. Containers, service meshes, microservices, immutable infrastructure, and declarative APIs exemplify this approach. Ref: https://github.com/cncf/toc/blob/master/DEFINITION.md
  11. 11. What is serverless? “An architectural approach to software solutions that relies on small independent functions running on transient servers in an elastic runtime environment.” Ref: Amundsen M. (2020). What is serverless?. O’Reilly Media
  12. 12. Serverless means a high level server abstraction, so you don't need to manage your servers anymore. Ref: Amundsen M. (2020). What is serverless?. O’Reilly Media
  13. 13. The fallacies of distributed computing” ● The network is reliable ● Latency is zero ● Bandwidth is infinite ● The network is secure ● Topology doesn’t change ● There is one administrator ● Transport cost is zero ● The network is homogeneous Ref: Amundsen M. (2020). What is serverless?. O’Reilly Media
  14. 14. Serverless Platform features ● Event-Driven ● Streaming Data ● Auto-Scaling ● Fault Tolerance Ref: Amundsen M. (2020). What is serverless?. O’Reilly Media
  15. 15. The Goods and the Bads ● Cheaper than the traditional cloud ● Scalable ● Lower Ops costs ● Focus on user experience/Devs Ref: https://dzone.com/articles/the-good-and-the-bad-of-serverless-architecture ● Vendor lock-in ● Learning curve ● Unsuitable for long-term tasks ● Doesnt support many languages
  16. 16. About controlling the system “they have a great deal of control over the design and definition of the solution but very little control over the system once it is deployed to the platform.” Ref: Amundsen M. (2020). What is serverless?. O’Reilly Media
  17. 17. Use Cases ● Internet of Things applications ● Virtual assistants and chatbots ● Auto-scaling Websites and APIs ● Event streaming(pub/sub,logs) ● Image and Video Manipulation ● Processing Events and SaaS ● Multi-language Applications ● CI/CD Ref: https://serverless.com/learn/use-cases/
  18. 18. What is Service Mesh? Is a dedicated infrastructure layer for handling service-to-service communication in order to make it visible, manageable, and controlled. Generally every service mesh is implemented as a series (or a “mesh”) of interconnected network proxies designed to better manage service traffic. Ref: Miranda G. (2018). The Service Mesh. O’Reilly Media.
  19. 19. Ref: https://containerjournal.com/topics/container-ecosystems/what-is-service-mesh-and-why-do-we-need-it/
  20. 20. Ref: https://containerjournal.com/topics/container-ecosystems/what-is-service-mesh-and-why-do-we-need-it/
  21. 21. Service Mesh has 2 components: ● data plane ● control plane Ref: Miranda G. (2018). The Service Mesh. O’Reilly Media.
  22. 22. Data plane The data plane is the layer responsible for moving your data (e.g., service requests) through your service topology in real time. Because this layer is implemented as a series of interconnected proxies and commonly deployed as one per communication endpoint. Just how “transparent” the communication is depends on the specific endpoint type you choose. Ref: Miranda G. (2018). The Service Mesh. O’Reilly Media.
  23. 23. Control plane A control plane exposes new primitives you can use to alter how your services communicate. You use the new primitives to compose some form of policy: routing decisions, authorization, rate limits, and so on. When that policy is ready for use, the data plane can reference that new policy and alter its behavior accordingly. Ref: Miranda G. (2018). The Service Mesh. O’Reilly Media.
  24. 24. Linkerd is an ultralight service mesh for Kubernetes. It gives you observability, reliability, and security without requiring any code changes. Ref: https://linkerd.io/
  25. 25. Ref: https://linkerd.io/
  26. 26. What does Linkerd do? ● Observability: Service-level golden metrics: success rates, latencies, throughput. Service topologies. ● Reliability: Retries, timeouts, load balancing, circuit breaking ● Security: Transparent mTLS, cert management and rotation, policy In an ultralight package focused on operational simplicity first and foremost. Ref: https://linkerd.io/
  27. 27. Why should I care? Linkerd gives ... ... platform owners (SREs, architects) ... the observability, reliability, and security primitives ... that are critical for cloud native architectures ... with no developer involvement! Linkerd doesn't just solve technical problems, it solves socio-technical problems: by decoupling them developers, it gives platform owners control over their destiny. 👈 Who? 👈 What? 👈 Why? 👈 The magic Ref: https://linkerd.io/
  28. 28. OpenFaaS OpenFaaS is an open source serverless platform to provide an easy for developers to deploy event-driven functions and microservices to Kubernetes without repetitive, boiler-plate coding. Package your code or an existing binary in a Docker image to get a highly scalable endpoint with auto-scaling and metrics. Ref: https://www.openfaas.com/
  29. 29. Features ● Ease UI portal and one-click install functions ● Package functions in any language for Linux/Windows using Docker/OCI image ● Portable, runs on existing hardware, public/private cloud, Kubernetes and Docker Swarm native ● CLI, YAML format for templating/defining functions ● Auto-scales as demand increases Ref: https://www.openfaas.com/
  30. 30. OpenFaaS Layers Ref: https://www.openfaas.com/
  31. 31. Reference Architecture Ref: https://docs.openfaas.com/architecture/stack/#conceptual-workflow
  32. 32. Serverless Real Use Case
  33. 33. Telecom needs Build a tool to create assisted chatbots that automate sales, support, monitoring, etc., using IM APIs from Slack, Telegram, Whatsapp, Facebook, etc.
  34. 34. Telecom Application requirements ● Prevent vendor lock-in ● Fast integration with technologies ● Short development time ● Implement DevOps & CI/CD ● Spend less money on cloud infrastructure ● Performance ● Resilience system ● Observability
  35. 35. Solution ● OpenFaaS(Serverless Platform) ● Linkerd(Canary Deployments, Observability) ● Kubernetes(Scaling & Orchestration)
  36. 36. Chatbot interactions Instant Messengers Platform Ref: https://www.doc.ic.ac.uk/project/examples/2005/163/g0516334/index.html
  37. 37. Serverless Chatbot Architecture Ref: https://github.com/openfaas-incubator/openfaas-linkerd2
  38. 38. Benefits for this solution ● Zero vendor lock-in ● Fast integration with technologies ● Short development time ● CI/CD ready platform ● Spend less money in a smart way ● Autoscalable application ● Resilience system ● Observability without modifications
  39. 39. Demo This demo shows: ● Claudia Slack Chatbot ● OpenFaaS functions templates ● Linkerd integrations ● Canary deployments ● Observability
  40. 40. https://github.com/sergioarmgpl/ linkerd-chatbots-openfaas
  41. 41. Questions
  42. 42. References ● George Miranda, The Service Mesh, O’Reilly Media ● Liran Tal. Serverless Security. O’Reilly Media ● Linkerd, https://linkerd.io ● OpenFaas, https://www.openfaas.com ● Container Journal, https://bit.ly/38qR3I9 ● Imperial College, Agents. https://bit.ly/2UmXFRV ● Serverless Use Cases, https://bit.ly/33uDO7F
  43. 43. Resources ● https://linkerd.io ● https://www.openfaas.com
  44. 44. Facebook: https://www.facebook.com/groups/cloudnativeplusgt Youtube: https://bit.ly/324h9N5 Meetup: https://www.meetup.com/cloud-native-plus-gt Twitter: https://twitter.com/cloudnativepgt
  45. 45. Personal email sergioarm.gpl@gmail.com Social networks @sergioarmgpl

×