[erlang-questions] Question about configuring gproc candidate nodes
Gregory Haskins
gregory.haskins@REDACTED
Tue Apr 19 22:26:17 CEST 2011
Hi Ulf, all,
I am still struggling to understand perhaps the best practices for
managing distributed gproc. Ultimately what I want is to have 1->N
controller nodes and an arbitrary number of subordinate nodes that are
all part of the same {, g, } gproc namespace. All nodes are booted with
an -boot script and therefore automatically load gproc and its
dependencies as the system comes up. What I was trying to do was use
something like "-gproc gproc_dist "['controller@REDACTED',
'controller@REDACTED']".
The problem that I run into is, of course, that on boot, a subordinate
node has not yet connected to something like 'controller@REDACTED' yet.
Therefore, using that config causes gproc_dist to fallback to local_only
mode and thus all {,g,} calls to blow up.
I have also tried booting all nodes with 'all', which only steals a
snapshot of the current node membership at startup (ala ['localhost']).
This allows gproc to enable global mode, but effectively creates
disjoint namespaces from the other members and is thus equally breaks my
app.
So far, the only thing that seems to work is to defer initializing the
gproc application until I manually connect to at least one controller in
the shell. If I then application:start(gproc), the gproc distribution
comes up with a unified namespace, as I would expect.
Is there a better way to do this?
Kind Regards,
-Greg
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 267 bytes
Desc: OpenPGP digital signature
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20110419/8e0e64a2/attachment.bin>
More information about the erlang-questions
mailing list