list_named_actors#
- ray.util.list_named_actors(all_namespaces: bool = False) List[str] | List[Dict[str, str]][source]#
List all named actors in the system.
Actors must have been created with Actor.options(name=”name”).remote(). This works for both detached & non-detached actors.
By default, only actors in the current namespace will be returned and the returned entries will simply be their name.
If
all_namespacesis set to True, all actors in the cluster will be returned regardless of namespace, and the returned entries will be of the form {“namespace”: namespace, “name”: name}.- Parameters:
all_namespaces (bool) – Whether to list named actors in all namespaces instead of only the current one.
- Returns:
A list of actor names, or, if
all_namespacesis True, a list of dicts with"name"and"namespace"keys.- Return type:
PublicAPI (beta): This API is in beta and may change before becoming stable.