- Actor encloses the state and application logic
- Actor interacts only using messages.
- Every actor has an exclusive address and mailbox through which he can receive messages from others.
- Mailbox messages are processed by the actor in consecutive order.
- Tree hierarchy is used to represent the actor system.
- Event-driven model — Actors perform work in response to messages. Communication between Actors is asynchronous, allowing Actors to send messages and continue their own work without blocking to wait for a reply.
- Strong isolation principles — Unlike regular objects in Java, an Actor does not have a public API in terms of methods that you can invoke. Instead, its public API is defined through messages that the actor handles. This prevents any sharing of state between Actors; the only way to observe another actor’s state is by sending it a message asking for it.
- Location transparency — The system constructs Actors from a factory and returns references to the instances. Because location doesn’t matter, Actor instances can start, stop, move, and restart to scale up and down as well as recover from unexpected failures.
- Lightweight — Each instance consumes only a few hundred bytes, which realistically allows millions of concurrent Actors to exist in a single application.
- Ask Pattern
- Ask Pattern mapTo
- Ask Pattern pipeTo
- Actor Hierarchy
- Actor Lookup
- Child actors
- Actor Lifecycle
- Actor PoisonPill
- Error Kernel Supervision
- RoundRobinPool
- ScatterGatherFirstCompletedPool
- TailChoppingPool
- BroadcastPool
- Akka Default Dispatcher
- Akka Lookup Dispatcher
- Fixed Thread Pool Dispatcher
- Resizable Thread Pool Dispatcher
- Pinned Thread Pool Dispatcher
Akka HTTP:
As the name implies, this module is typically best suited for middle-tier applications which require an HTTP endpoint. As an example, you could use Akka HTTP to expose a REST endpoint that interfaces with a storage layer such as a database. For additional information, you can refer to the official Akka documentation on Akka HTTP.
Akka Streams:
This module is useful when you are working on data pipelines or even stream processing. For additional information, you can refer to the official Akka documentation on Akka Streams.
Akka Networking:
This module provides the foundation for having actor systems being able to connect to each other remotely over some predefined network transport such as TCP. For additional information, you can refer to the official Akka documentation on Akka Networking.
Akka Clustering:
This module is an extension of the Akka Networking module. It is useful in scaling distributed applications by have actors form a quorum and work together by some predefined membership protocol. For additional information, you can refer to the official Akka documentation on Akka Clustering.
For Creating a Simple Application,use the below link
https://developer.lightbend.com/start/?group=akka&project=akka-quickstart-java
No comments:
Post a Comment