The actor registry in CAF keeps track of the number of running actors and allows to map actors to their ID or a custom atom (see § :ref:`atom <#atom>`__) representing a name. The registry does not contain all actors. Actors have to be stored in the registry explicitly. Users can access the registry through an actor system by calling
system.registry(). The registry stores actors using
strong_actor_ptr (see § :ref:`actor-pointer <#actor-pointer>`__).
Users can use the registry to make actors system-wide available by name. The middleman (see § :ref:`middleman <#middleman>`__) uses the registry to keep track of all actors known to remote nodes in order to serialize and deserialize them. Actors are removed automatically when they terminate.
It is worth mentioning that the registry is not synchronized between connected actor system. Each actor system has its own, local registry in a distributed setting.
|``strong_actor_ptr get(actor_id)` `||Returns the actor associated to given ID.|
||Returns the actor associated to given name.|
||Returns all name mappings.|
||Returns the number of currently running actors.|
||Maps an actor to its ID.|
||Removes an ID mapping from the registry.|
||Maps an actor to a name.|
||Removes a name mapping from the registry.|