4.12 Module classy_site_metadata

This module provides an API for setting persistent site properties. These properties survive node restarts and cluster changes.

Each site property has either of two visibility types:

  1. site site properties are not tied to any particular cluster, and are not visible to the peers.

    Joining or leaving the cluster doesn’t change visibility of the site-private properties.

  2. cluster cluster properties are tied to the cluster ID, and they are replicated across the cluster via gossip protocol.

Cluster and site properties are independent: they exist in two different “namespaces”.

classy_site_metadata:c_set(foo, bar).
classy_site_metadata:c_set(bar, baz).

...
classy:get_meta(Site) ->
  #{ foo => bar
  , bar => baz
   }.
JavaScript license information