Akka: Event-driven Middleware for Java and Scala

Akka is an event-driven middleware framework, implemented in Scala, for building high performance and reliable distributed applications. Akka decouples business logic from low-level mechanisms such as threads, locks and non-blocking IO. Your Scala or Java program logic lives in lightweight Actor objects which send and receive messages. With Akka, you can easily configure how Actors will be created, destroyed, scheduled, and restarted upon failure.

Simpler Concurrency

Threads and nonblocking IO are complex and error-prone to work with by hand, which means they waste your time. With Akka's implementation of the Actor concurrency model, you are freed focus on your application's business logic and let the framework think about scaling out.  

Transactions

In addition to Actors, Akka provides software transactional memory (STM). Rather than working with threads and locks by hand, transactional memory lets you atomically modify the state of many objects at once, reverting all your changes if the transaction fails. STM is combined with Actors in the Akka concept of "Transactors".

Event-driven

Akka is an ideal platform for asynchronous event-driven architectures, and can be configured to use non-blocking IO frameworks. 

Scalability

Scale out on multicore servers and multiple nodes using Akka's support for asynchronous message passing.  On a commodity machine, you might run several million Actors -- quite a step up from mere thousands of threads in a traditional Java application.

Fault-tolerance

Akka provides fault-tolerance based on supervisor hierarchies.  A supervisor is responsible for monitoring its child Actors and restarting them when necessary. Instead of trying all things possible to prevent an error from happening, this approach lets you embrace the reality of unplanned errors. It means you can adopt a pragmatic ‘Let It Crash’ philosophy, with the confidence that the impacted components will be reset to a stable state and restarted upon failure.

Transparent Remoting

Akka's Remote Actors provide a high-performance and transparent distributed programming model.  Actors running on remote nodes look just like those running locally.  This gives you a unified programming model for multicore and distributed computing workloads.

Scala & Java APIs

In keeping with the pragmatism of the Typesafe Stack, Akka has a Java API in addition to a Scala API. Which means smooth interoperability, and no need to adopt Scala wholesale in every codebase at once. Akka offers Spring and Guice integrations, and can be deployed in your existing Java application server or run stand-alone.

Open Source

Akka is open source and available under the Apache 2.0 License.  It is available as part of the open source Typesafe Stack.

Akka was originally created by Typesafe co-founder Jonas Bonér. You can learn more about Akka at the Akka community website.

Join the newsletter

Stay up to date on Typesafe news, events, tips, and more.

The Typesafe Stack

Download the Typesafe Stack installer:

Learn more in the whitepaper.

Free e-book

Download Scala for the Impatient.