4.1.14 fallback_get_peer_nodes(Hook)

-spec fallback_get_peer_nodes(fun((node()) -> {ok,
                                               [node()]} |
                                              undefined)) -> classy_hook:hook().

Fallback: get list of peer nodes of a given node.

When a classy-aware node joins to another node via the fallback mechanism, its peer information is seeded by running classy:fallback_get_site/1, classy:fallback_get_cluster/1 and classy:fallback_get_meta/2 hooks for each node returned by this hook, called with the node that is the target of join_node operation.

The following limitations apply:

  1. All nodes must have the same cluster ID, or join operation is aborted.
  2. This hook runs once, during the join operation.

    If more nodes that are not classy-aware join or leave the cluster, classy will ignore these changes.

    Note that the fallback mechanism is meant for rolling upgrade. It implies that all nodes subsequently update to classy-aware code.

JavaScript license information