[erlang-questions] Why RPC in Erlang? [was: How RPC works in erlang?]

Roger Lipscombe roger@REDACTED
Fri Oct 6 11:43:48 CEST 2017


On 6 October 2017 at 03:37, zxq9 <zxq9@REDACTED> wrote:
> Thinking that the rpc module is specially useful for tests, CLI
> wrappers, or when you want to execute commands on a remote node (from
> a script or otherwise) is a bit of an odd conclusion to draw, given
> the way that the even-arity spawn_* functions work.

On occasion, we've needed to (e.g.) tweak application settings in a
remote node, at runtime, during system tests, synchronously. Sure, I
could do that with spawn_*, but that's a lot of plumbing I'd need to
write. Hey, look: someone already did; it's in the rpc module.

We *also* use spawn_*; we've even got some code that pushes a local
module into the remote node, and spawns a process running *that*, but
sometimes: you just want what the rpc module offers.

I also note that erl_call uses the "rex" server...



More information about the erlang-questions mailing list