distribute/registry
Types
pub type RegisterError {
AlreadyRegistered
InvalidProcess
InvalidName(String)
NetworkError(String)
RegisterFailed(String)
}
Constructors
-
AlreadyRegisteredName is already registered by another process.
-
InvalidProcessProcess is not alive or invalid.
-
InvalidName(String)Name contains invalid characters or is too long.
-
NetworkError(String)Network partition or connectivity issue.
-
RegisterFailed(String)Generic registration failure.
Values
pub fn register(
name: String,
pid: Pid,
) -> Result(Nil, RegisterError)
Register a process globally under the given name.
pub fn unregister(name: String) -> Result(Nil, RegisterError)
Unregister a globally registered name.
pub fn whereis(name: String) -> option.Option(Pid)
Look up a globally registered process by name. Returns Some(pid) if found, None otherwise.