skycluster v1.1.3 Cluster.Events

This module implements a publish/subscribe mechanism for cluster events.

Link to this section Summary

Link to this section Functions

Link to this function publish(event)
publish(event :: term) :: :ok

Publishes an event to all subscribers.

Published messages are delivered via send/2, so if subscribing a gen_* process, you will receive them in the handle_info/2 callback.

Link to this function subscribe(pid)
subscribe(pid) :: :ok

Subscribes a process (by pid) to cluster events.

Link to this function system_code_change(misc, module, old, extra)
Link to this function system_continue(parent, debug, state)
Link to this function system_get_state(state)
Link to this function system_replace_state(state_fun, state)
Link to this function system_terminate(reason, arg2, debug, state)
Link to this function unsubscribe(pid)
unsubscribe(pid) :: :ok

Unsubscribes a process (by pid) from cluster events.