In the preceding application, we created a simple cluster consisting of two members: one running in port 2552 (using application-cluster-1.conf) and another running in port 2553 (using application-cluster-2.conf).
The actor system consists of two actors:
- NotificationSubscriber: This actor subscribes itself to the topic called notification by sending a subscribe message to the mediator. The mediator actor is accessed through the DistributedPubSub extension. It sends a SubscribeAck message once the subscription is ready. From then on, any message published to the notification topic will be received by this actor.
- NotificationPublisher: This actor gets a reference of the mediator through the DistributedPubSub extension. Every ...