Book Image

Learning Akka

By : Jason Goodwin
Book Image

Learning Akka

By: Jason Goodwin

Overview of this book

<p>Software today has to work with more data, more users, more cores, and more servers than ever. Akka is a distributed computing toolkit that enables developers to build correct concurrent and distributed applications using Java and Scala with ease, applications that scale across servers and respond to failure by self-healing. As well as simplifying development, Akka enables multiple concurrency development patterns with particular support and architecture derived from Erlang’s concept of actors (lightweight concurrent entities). Akka is written in Scala, which has become the programming language of choice for development on the Akka platform.</p> <p>Learning Akka aims to be a comprehensive walkthrough of Akka. This book will take you on a journey through all the concepts of Akka that you need in order to get started with concurrent and distributed applications and even build your own.</p> <p>Beginning with the concept of Actors, the book will take you through concurrency in Akka. Moving on to networked applications, this book will explain the common pitfalls in these difficult problem areas while teaching you how to use Akka to overcome these problems with ease.</p> <p>The book is an easy to follow example-based guide that will strengthen your basic knowledge of Akka and aid you in applying the same to real-world scenarios.</p>
Table of Contents (17 chapters)
Learning Akka
Credits
About the Author
Acknowledgments
About the Reviewer
www.PacktPub.com
Preface
Index

Homework


This chapter is a blend of theory and technique. We covered how to use Akka cluster to run work on and then how to use it to distribute datasets partitioned by key. The problems are too big to cover in an introductory chapter to Cluster, but if you try to approach some of the problems presented in this chapter, you should start to get a good handle on how people solve some of these problems today.

  • Build your own worker queue using Cluster.

  • Build a distributed key-value store with replication.

  • Try to solve the linearization problem—how can you determine ordering? How can you "repair" nodes that fail and then recover?

  • Build a distributed key-value store with sharding.

  • Can you combine sharding and replication with minimal changes to the code you have now as described?

  • In the sharded model, can you develop a way to redistribute data to new nodes? Is it harder to do this with replication? About the same difficulty?

  • If you build a project, you should open source it and share your discoveries...