Connecting cluster with different cookies

Raimo Niskanen raimo+erlang-questions@REDACTED
Tue Aug 10 10:52:00 CEST 2021

To clarify; we are not talking about deleting the possibility
to set the default cookie for the node through an API function,
although today the only way to do that is by calling
erlang:set_cookie(node(), Cookie).

An obvious erlang:set_cookie(Cookie) is missing and could be added.

It is setting differing cookies for other nodes that is the feature
scrutinized here i.e erlang:set_cookie(OtherNode, OtherCookie).

All your use cases; can they be solved by setting the default cookie
for the node?  E.g starting a node to just to interact with a cluster,
is it needed/desirable to be able to interact with several clusters
simultaneously, or do you start a dedicated node for that interaction,
hence would it be possible to just set the default cookie for the
interaction node during the interaction?

/ Raimo Niskanen

On Mon, Aug 09, 2021 at 06:21:00PM +0200, Raimo Niskanen wrote:
> Hello Community.
> Regarding a GitHub Issue in progress:
> and a corresponding pull request:
> There is an apparently rarely known API call
> erlang:set_cookie(Node, Cookie) that allows you to configure
> a cookie to use when communicating with a different node.
> This/these set cookie/s may/should be different from the node's
> normal (default) cookie, and the functionality exists
> to make it possible to connect nodes that have different
> default cookies.
> The feature is probably rarely used; almost nobody in the
> OTP group knew that it existed nor how it is supposed
> to be used.  Connecting only nodes with the same cookie
> seems to be the norm.
> The question is now, is this an essential feature / how
> important is this feature?
> To completely remove this feature would simplify the code,
> but if that should destroy an important use case; removing
> would not be an option.
> The Issue and PR is about how it is supposed to work; if and
> how it should be fixed.
> So, what says the Community?  How important feature is it
> to be able to connect nodes with different cookies?
> Cheers
> -- 
> / Raimo Niskanen, Erlang/OTP, Ericsson AB


/ Raimo Niskanen, Erlang/OTP, Ericsson AB

More information about the erlang-questions mailing list