Evolving an Actor Library Based on Lessons Learned from Large-Scale Deployments – Benjamin Hindman

  • Lobby
  • Science & Technology
  • Evolving an Actor Library Based on Lessons Learned from Large-Scale Deployments – Benjamin Hindman

https://cppcon.org/
https://github.com/CppCon/CppCon2020
---
To meet the performance demands of a large-scale container orchestrator (Apache Mesos) we built a pre-C++11 library that, in 2009, was the first library we knew of that combined an actor programming model with futures/promises. In the first part of this talk we'll discuss why we chose to use futures/promises to build a large-scale distributed system and why actors are the perfect complementary programming model. The library served us well, helping to scale Mesos to clusters larger than 75,000 physical machines, but not without numerous bouts of optimizations and introductions of new, more efficient, constructs. We'll discuss what we learned along the way, in particular that while the intention and interface of the library was good, the underlying implementation of the library performed tons of unnecessary synchronization and dynamic memory allocation.

Now 10 years later we've rebuilt the library from scratch as part of ongoing research into distributed systems at UC Berkeley. We'll discuss how the new library focuses on *continuations* rather than futures/promises while providing the same simplicity as before when composing code. We'll walk through how programmers can use low-level constructs of the library to explicitly compose continuations together, or how they can use higher-level constructs that they can compose without using continuations at all.

The library is coroutine friendly and has some overlap with 'A Unified Executors Proposal for C++' (P0443R13), in particular that both approaches are lazy vs the eager approach of futures/promises. However, our library has a particular focus on supporting actors. This has some important design implications with respect to scheduling and memory allocation that we'll discuss in depth during this presentation, highlighting some of the differences with outstanding proposals.

---
Benjamin Hindman

Benjamin Hindman is one of the creators of Apache Mesos. He began working on the project as a PhD student at UC Berkeley, and it followed him to Twitter where he is currently employed. Mesos now runs on thousands of machines at Twitter, Airbnb, etc. -- even when Ben is away skiing in Tahoe or surfing in Santa Cruz. An academic at heart, Ben's research in the areas of programming languages and distributed systems has been published in leading academic conferences. Ben has spoken about his research, Mesos, and his libprocess and stout libraries at numerous conferences and companies. He most recently spoke at FutureStack in SF and the Hadoop Summit Asia in Beijing.

---
Videos Filmed & Edited by Bash Films: http://www.BashFilms.com

YouTube Channel Managed by Digital Medium Ltd https://events.digital-medium.co.uk

The CppCon YouTube Channel Is Sponsored By:
JetBrains : http://jb.gg/cpptools
SonarSource: https://www.sonarsource.com/

Filed under: Science & Technology

No comment yet, add your voice below!


Add a Comment