Skip to main content
Newer Version Available

This is documentation for version 2.11.0. See the latest version.

Distributed Actor System

Coming Soon

This documentation is under development.

Overview

The Distributed Actor System extends POJO-actor to support actors running across multiple JVMs and machines, enabling scalable and fault-tolerant applications.

Topics to be Covered

  • Actor location transparency
  • Remote actor references
  • Message serialization
  • Network protocols (TCP, gRPC)
  • Cluster membership and discovery
  • Actor migration
  • Fault tolerance and supervision
  • Split-brain handling

Architecture

┌─────────────────────────────────────────────────────────────────┐
│ Actor Cluster │
├─────────────────┬─────────────────┬─────────────────────────────┤
│ Node A │ Node B │ Node C │
│ ┌──────────┐ │ ┌──────────┐ │ ┌──────────┐ │
│ │ Actor 1 │◄──┼──┤ Actor 2 │◄──┼──┤ Actor 3 │ │
│ └──────────┘ │ └──────────┘ │ └──────────┘ │
│ ┌──────────┐ │ ┌──────────┐ │ │
│ │ Actor 4 │ │ │ Actor 5 │ │ │
│ └──────────┘ │ └──────────┘ │ │
└─────────────────┴─────────────────┴─────────────────────────────┘

Conceptual Example

// Conceptual distributed actor system
DistributedActorSystem system = DistributedActorSystem.builder()
.clusterName("my-cluster")
.seedNodes("192.168.1.1:2551", "192.168.1.2:2551")
.build();

// Create local actor
ActorRef<Worker> local = system.actorOf("local-worker", new Worker());

// Get reference to remote actor
ActorRef<Worker> remote = system.remoteActorOf(
"akka://[email protected]:2551/user/remote-worker"
);

// Message passing works the same way
remote.tell(w -> w.process(data));

Use Cases

  • Horizontally scalable services
  • Geographically distributed systems
  • High-availability applications
  • Load balancing across nodes

This page will be expanded with detailed documentation and examples.