Book Image

Mastering Akka

By : Christian Baxter
Book Image

Mastering Akka

By: Christian Baxter

Overview of this book

For a programmer, writing multi-threaded applications is critical as it is important to break large tasks into smaller ones and run them simultaneously. Akka is a distributed computing toolkit that uses the abstraction of the Actor model, enabling developers to build correct, concurrent, and distributed applications using Java and Scala with ease. The book begins with a quick introduction that simplifies concurrent programming with actors. We then proceed to master all aspects of domain-driven design. We’ll teach you how to scale out with Akka Remoting/Clustering. Finally, we introduce Conductr as a means to deploy to and manage microservices across a cluster.
Table of Contents (17 chapters)
Mastering Akka
Credits
About the Author
Acknowledgments
About the Reviewer
www.PacktPub.com
Preface

Chapter 8. Scaling Out with Akka Remoting/Clustering

Within the realm of scaling, there are two main techniques that people use to scale their software. The first of those techniques is called scaling up, or vertical scaling. In this technique, you can increase the horsepower of the box the software is running on. This can include adding more CPUs or increasing the memory. The idea here is that by increasing the headroom on the box, the software now has the ability to do more work than before. Akka is a great framework for scaling up as it will allow you to take advantage of those multiple-CPU cores as you add them.

This seems like a pretty simple technique as it doesn't involve any re-architecture of your software. Unfortunately, it may not be the most cost-effective. With most cloud providers, you pay a steep premium for the bigger boxes. It may be smarter to try and spread your work over many smaller boxes, and that's where the second scaling technique comes into play.

Scaling out, or horizontal...