The Actor model is a mathematical model of concurrent computation whose core idea is that "everything is an actor." An actor is a computational entity that, upon receiving a message, can concurrently perform three types of actions: send a finite number of messages to other actors; create a finite number of new actors; and designate the behavior to be used for handling the next message. These actions have no assumed order of precedence and can be executed in parallel.
Key capabilities and characteristics:
- Message-passing decoupling: the sender is decoupled from the communication process, asynchronous communication is supported, and control structures are formed through the message-passing pattern.
- Address-based addressing: message recipients are identified by addresses (sometimes called "mailing addresses"); an actor can communicate only with actors whose addresses it has, and addresses may come from received messages or from actors it created itself.
- Inherent concurrency: there is inherent concurrency within and among actors, dynamic creation of actors is supported, messages contain actor addresses, interaction occurs only through direct asynchronous message passing, and the order in which messages arrive is not constrained.
- Private state: an actor can modify its own private state, but actors can only influence one another indirectly through message passing, thereby eliminating the need for lock-based synchronization.
Usage and theoretical forms: the material introduces a variety of formal systems for reasoning about Actor model systems, including operational semantics, laws of Actor systems, denotational semantics, and transition semantics; it also mentions some formalizations that are not fully faithful to the Actor model (such as certain Actor algebras and linear logic), because they do not formalize the guaranteed delivery of messages.
Applicable scenarios: the Actor model can serve as a framework for modeling, understanding, and reasoning about various concurrent systems. Examples given in the material include: email can be modeled as an Actor system (accounts as actors, mailbox addresses as actor addresses); web services can be modeled as actors, with SOAP endpoints as actor addresses; objects with locks (such as in Java and C#) can be modeled as serializers, provided their implementation allows messages to keep arriving (for example, by storing them in an internal queue); TTCN-2 and TTCN-3 are relatively close to the Actor model, in which actors are test components (parallel test components, PTCs, or the main test component, MTC), test components can send and receive messages to and from remote partners, and each test component is bound to a behavior tree, can run in parallel, and can be dynamically created by a parent test component.
History and background: the Actor model originated in 1973. According to Carl Hewitt, unlike previous computational models, itSimilarly, it is inspired by physics (including general relativity and quantum mechanics), and also influenced by Lisp, Simula, early Smalltalk, capability-based systems, and packet switching. Its development motivation was highly parallel computing machines composed of tens, hundreds, or even thousands of independent microprocessors, each with local memory and a communication processor, communicating over a high-performance communication network. Since then, the large-scale concurrency brought by multicore and many-core architectures has rekindled interest in the Actor model.
Message-passing semantics and controversy: The Actor model focuses on the semantics of message passing. The material discusses the unbounded nondeterminism controversy: Dijkstra's model cannot provide service guarantees, whereas Hewitt believed that the Actor model should provide service guarantees; the Actor model has unbounded nondeterminism, and Will Clinger provided a mathematical model using domain theory. In the Actor model there is no global state. Messages are not necessarily buffered; they are simply sent like IP packets, without requiring a synchronous handshake with the receiver. Actor creation plus addresses in messages means a mutable topology; an Actor can create new Actors and include the addresses of other Actors in messages, thereby forming arbitrarily mutable topological relationships. The Actor model was developed as an inherent concurrency model, and sequentiality is only a special case of concurrent computation. The material also points out that messages are not required to arrive in the order they were sent; if output message ordering is needed, a queue Actor can provide this function in FIFO order.
Limitations and omissions: The material does not provide information such as specific software products, installation commands, pricing, platform support, or usage steps, and none is currently provided.