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.

The Reactive Edge: Reinventing the Edge Tier Using a Reactive Communication Protocol

18 views

Published on

There is a huge demand for responsive, real-time mobile and web experiences, but current architectural patterns do not easily accommodate applications that respond to events in real time. Common solutions using message queues or HTTP long-polling quickly lead to resiliency, scalability, and development velocity challenges, due to the need to manage queues and develop complex workarounds for problems like thundering herds and dropped events. By adopting a protocol providing Reactive Streams semantics over the network boundary, we have been able to solve many of these problems at the communication layer. Using streams, data can be pushed to clients when it changes instead of having to long poll, while backpressure obviates the need for queues throughout the system. This makes it possible to create rich application experiences and support use-cases such as mobile-to-mobile communication and large file transfers that would be difficult or cost-prohibitive with traditional networking.

Published in: Technology
  • Be the first to comment

  • Be the first to like this

The Reactive Edge: Reinventing the Edge Tier Using a Reactive Communication Protocol

  1. 1. The Reactive Edge: Reinventing the Edge Tier Using a Reactive Communication Protocol Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com
  2. 2. Who Am I? Ryland Degnan Chief Technical Officer at Netifi Formerly Netflix Edge Platform Team Contributor to RSocket, RxNetty linkedin.com/in/rjdegnan twitter.com/rjdegnan Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com
  3. 3. “The Internet was done so well that most people think of it as a natural resource like the Pacific Ocean, rather than something that was man-made. When was the last time a technology with a scale like that was so error-free? The Web, in comparison, is a joke. The Web was done by amateurs.” —Alan Kay The Web is a Joke… Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com Source: http://www.drdobbs.com/architecture-and-design/interview-with-alan-kay/240003442
  4. 4. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com The Web is a Joke…
  5. 5. Increased Connectivity Massive Mobile Device Growth Realtime Interaction Expected The World is Changing… Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com
  6. 6. Image Messaging New connected experiences are being created everyday VR Video GamesVideo Streaming The World is Changing… Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com
  7. 7. Communication Communication is the foundation that all of these experiences are built upon Communication Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com
  8. 8. HTTP Would you build your house on an old foundation? Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com
  9. 9. The Foundation is Rotten HTTP 25+ year old technology Inefficient Not designed for today’s experiences Insecure Expensive to Operate Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com
  10. 10. Time to Change the Foundation More Performant More Secure Cheaper and Easier to Build Faster Time to Market By changing the way applications communicate you can easily build rich experiences Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com
  11. 11. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com HTTP
  12. 12. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com HTTP
  13. 13. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com HTTP
  14. 14. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com HTTP
  15. 15. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com HTTP
  16. 16. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com HTTP
  17. 17. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com HTTP
  18. 18. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com HTTP
  19. 19. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com HTTP
  20. 20. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com HTTP
  21. 21. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com HTTP
  22. 22. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com HTTP
  23. 23. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com HTTP Thundering herds Cascading failure Circuit breaking Retry logic Timeouts Configuration
  24. 24. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com HTTP TCP is full-duplex! Can’t we do better?
  25. 25. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com Streams RSocket
  26. 26. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com Streams RSocket
  27. 27. 2 2 2 Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com RSocket Streams
  28. 28. 2 2 2 Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com RSocket Streams
  29. 29. 2 2 2 Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com RSocket Streams
  30. 30. 2 2 2 2 2 2 Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com RSocket Streams
  31. 31. 2 2 2 2 2 2 Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com RSocket Streams
  32. 32. 2 2 2 Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com RSocket Streams
  33. 33. 2 2 2 Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com RSocket Streams
  34. 34. 2 2 2 Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com RSocket Streams
  35. 35. 2 2 2 Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com RSocket Streams
  36. 36. 2 2 2 Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com Streams RSocket
  37. 37. 2 2 2 Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com Streams RSocket
  38. 38. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com HTTP
  39. 39. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com HTTP
  40. 40. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com RSocket
  41. 41. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com RSocket
  42. 42. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com RSocket
  43. 43. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com RSocket
  44. 44. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com RSocket
  45. 45. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com RSocket
  46. 46. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com What is the Problem? Lots of Moving Parts Communicating between applications is complicated and inefficient. Complicated Server and Application Configuration Unable to Cancel Work in Progress Server Unable to Signal When Ready to Handle Traffic Errors are Hard to Handle
  47. 47. RSocket Reactive Streams over network boundaries Application flow control, supports cancellation of work in progress Collaboration between Netflix, Facebook, Pivotal and others Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com A Better Foundation Reactive Streams Common interfaces for streaming data across an asynchronous boundary Collaboration between Netflix, Twitter, Pivotal, Red Hat, Lightbend and others Reactive Edge Layer Self healing, no configuration of queues or circuit breakers Transparent discovery, load balancing, caching, authentication/encryption Handle common infrastructural concerns at the edge level Many implementations, now supported in JDK 9 Flow API
  48. 48. Reactive Edge: A Netflix Case Study Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com
  49. 49. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com Reactive Edge: A Netflix Case Study
  50. 50. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com The Netflix API circa 2008 Fine-grained REST API forces client applications to make multiple calls that need to be assembled Mobile clients pay the price of WAN latency multiple times Ignores differences between devices Poor developer velocity for UI teams No fault tolerance isolation layer
  51. 51. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com The Netflix API circa 2013
  52. 52. Where is the Edge? Source: https://www.capgemini.com/2017/03/what-is-fog-and-edge-computing/ Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com
  53. 53. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com Netflix Edge Layer in 2017
  54. 54. Where is the Edge? Source: https://www.capgemini.com/2017/03/what-is-fog-and-edge-computing/ Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com
  55. 55. Edge PoPs Core regions Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com Where is the Edge?
  56. 56. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com The Netflix Edge circa 2013
  57. 57. Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com The Netflix Edge circa 2017 iOS Endpoint Android Endpoint Xbox Endpoint Middle Tier & Platform
  58. 58. Global Edge Network Edge Router Edge Router iOS Endpoint Load Balancer Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com Region A Region B Stream Processing iOS User
  59. 59. SIMPLIFYING MOBILE APPLICATION COMMUNICATION Simplifying Mobile Application Communication Ryland Degnan ryland@netifi.com

×