[erlang-questions] global:set_lock/1 vs gen_leader & gen_paxos

Paul Mineiro paul-trapexit@REDACTED
Tue Sep 1 16:23:08 CEST 2009


I used global:set_lock/1 for just this purpose, but it was an operation
that happened infrequently (daily) and the number of nodes in my cluster
never exceeded 24.

It worked so I never tested the alternatives.

-- p

On Tue, 1 Sep 2009, Joel Reymont wrote:

> Suppose I need a single node (process) in a cluster to write to a file
> on Amazon S3. I don't care which node does it since all I'm doing is
> writing a list of nodes to the file.
>
> I could try to elect a leader with gen_leader or come to consensus
> with gen_paxos. What are the drawbacks of using global:set_lock/1
> instead, though?
>
> 	Thanks, Joel
>
> ---
> fastest mac firefox!
> http://wagerlabs.com
>
>
> ________________________________________________________________
> erlang-questions mailing list. See http://www.erlang.org/faq.html
> erlang-questions (at) erlang.org
>
>



More information about the erlang-questions mailing list