rodario¶
A simple, redis-backed Python actor framework
Contents:
-
class
rodario.registry.
Registry
¶ Actor registry class (singleton wrapper)
-
static
__new__
()¶ Retrieve the singleton instance for Registry.
Return type: rodario.registry._Singleton
-
static
-
class
rodario.registry.
_Singleton
¶ Singleton for actor registry
-
__init__
()¶ Initialize the registry.
-
exists
(uuid)¶ Test whether an actor exists in the registry.
Parameters: uuid (str) – UUID of the actor to check for Return type: bool
-
get_proxy
(uuid)¶ Return an ActorProxy for the given UUID.
Parameters: uuid (str) – The UUID to return a proxy object for Return type: rodario.actors.ActorProxy
-
-
class
rodario.actors.
Actor
(uuid=None)¶ Base Actor class
-
proxy
()¶ Wrap this Actor in an ActorProxy object.
Return type: rodario.actors.ActorProxy
-
start
()¶ Fire up the message handler thread.
-
stop
()¶ Kill the message handler thread.
-
-
class
rodario.actors.
ActorProxy
(actor=None, uuid=None)¶ Proxy object that fires calls to an actor over redis pubsub
-
__init__
(actor=None, uuid=None)¶ Initialize instance of ActorProxy.
Accepts either an Actor object to clone or a UUID, but not both.
Parameters: - actor (rodario.actors.Actor) – Actor to clone
- uuid (str) – UUID of Actor to clone
-