Learn reactive programming by building a modern, message-driven, resilient, responsive, and elastic system
About This Book
- Explore the advanced concepts such as data flow, event-based programming, and higher order reactive programming
- Get to grips with reactive programming for improved event handling and code resilience
- Create a scalable application from scratch using Scala and Akka through this step-by-step guide
Who This Book Is For
If you are a software engineer who is familiar with functional or object-oriented programming languages such as Erlang, Haskell, C#, or Java, and want to learn about the reactive programming paradigm, this book is for you. It would be helpful to have some familiarity with basic functional programming concepts, but no prior reactive programming experience is required.
What You Will Learn
- Understand the difference between event-driven and thread-based concurrency and where the message-driven pattern succeeds
- Explore various production-ready technologies, languages, and libraries you can use in your projects
- Create a scalable REST API using the Actor concurrency model implemented by Akka
- Manipulate and handle events applying the Observer and Future patterns using Akka Stream
Gain the best strategies and hierarchy designs to recover from failure - Implement reactive persistence to enable restart and recovery from an application crash
- Expand the monitoring capabilities to a complex and distributed supervision hierarchy using child Actors
- Distribute the system between clusters using remote nodes to scale the message exchange between Actors
In Detail
Reactive programming principles allow you to scale your existing application or develop a new product by constructing or modifying your components. A message-driven pattern is the one-stop-shop for either simple or complex software systems as it solves many problems natively.
This book starts with an introduction to message-driven architecture. Then, we go through Scala, Haskel, and other languages and identify the right tools to develop our system. Moving on, you will learn to create a scalable REST API and deep dive into reactive event handling by developing an aggregation service using Akka Stream and Observer Pattern. Following this, we provide you with strategies to identify tactics to provide fault tolerance and recover from errors. Next, we’ll show you reactive persistence, which will help you implement persistent actors in the aggregation service. The last part of the book will show you how to implement the resiliency and responsiveness aspect of reactive programming, and create replicated components simulating a scalable environment.
By the end of the book, you will be able to implement the knowledge gathered through this book using the languages you already know or using Reactive libraries.