Questions tagged [erlang]

Erlang is a general-purpose, garbage-collected programming language and runtime environment, with built-in support for concurrency, distribution and fault tolerance.

Erlang is a general-purpose functional programming language and runtime environment. It has built-in support for concurrency, distribution and fault tolerance. Erlang is used in several large telecommunication systems from Ericsson. Erlang is open source and available for download on GitHub.

Some Erlang features:

Online Resources:

Erlang Books:

9600 questions
16
votes
6 answers

Erlang : Disallowed Nodes / Maybe Cookie question

Trying to get two erlang nodes talking to each other : one on a Ubuntu machine and one on Windows XP. We're getting a "Connection attempt from disallowed node" message which prevents one node receiving messages from the other. They're both using…
interstar
  • 26,048
  • 36
  • 112
  • 180
16
votes
4 answers

How Do You Determine The PID of the Parent of a Process

I have a process in erlang that is supposed to do something immediately after spawn, then send the result back to the parent when it is finished. How do I figure out the PID of the process that spawned it?
ricree
  • 35,626
  • 13
  • 36
  • 27
16
votes
3 answers

How do I convert an integer to a binary in Erlang?

I am trying to make an integer into a binary: 543 = <<"543">> How can I do this without integer_to_list(list_to_binary(K)).
BAR
  • 15,909
  • 27
  • 97
  • 185
16
votes
1 answer

Shutdown Error in RabbitMq sasl Log

We are running RabbitMq 3.6.2 with Erlang 17.4 on Windows Server 2008. We see the following record over and over in the sasl log. It is occurring sparratically (every few hours) with no particular pattern. =SUPERVISOR REPORT====…
doug144
  • 387
  • 3
  • 9
16
votes
4 answers

What are some good Erlang Primers/Tutorials for beginners?

What are some good links for diving into Erlang and functional programming in general?
semmons99
  • 1,134
  • 1
  • 9
  • 13
16
votes
2 answers

Erlang Programming: Will Learning Prolog Help?

Will learning Prolog help to learn Erlang in a way specific to Erlang? Erlang started as a concurrent Prolog, but is modern Erlang connected to Prolog (beyond syntax)? I understand that learning Prolog might be good in the way learning Lisp is good…
Duke of Erl
  • 161
  • 2
16
votes
2 answers

In Elixir/Erlang, which port is used for `Node.connect`?

One can init a Elixir node by iex using: iex --sname node1@10.99.1.50 --cookie foo And then another one can connect this node in REPL using: Node.connect(:"node1@10.99.1.50") It seems the connection is over TCP protocol. However, I didn't find a…
Hanfei Sun
  • 45,281
  • 39
  • 129
  • 237
16
votes
1 answer

What is the difference between rebar and rebar3? or erlang.mk

I am very new to Erlang programming language. Is there a standard build tool in Erlang? I have googled out these, not sure which one I should use. I don't know that what kind of occasion is it used for?
Leviathan
  • 335
  • 2
  • 5
  • 10
16
votes
1 answer

How to create and use a custom Erlang behavior?

Trying to define a custom behaviour in Erlang, I cannot figure out a way to apply the callback function inside the behaviour definition module. The compiler claims, the callback function is undefined. I was expecting a callback function in a…
Jörgen Brandt
  • 210
  • 2
  • 9
16
votes
3 answers

How can I pass command-line arguments to a Erlang program?

I'm working on a Erlang. How can I pass command line parameters to it? Program File- -module(program). -export([main/0]). main() -> io:fwrite("Hello, world!\n"). Compilation Command: erlc Program.erl Execution Command- erl -noshell -s…
Monti Chandra
  • 432
  • 5
  • 21
16
votes
1 answer

With Boost.Fiber does c++ come one step closer to Erlang style process/threads?

I am reading http://olk.github.io/libs/fiber/doc/html/ It seems to me that with Boost.Fiber C++ is coming closer to Erlang's ability to have thousands of "processes", also known as "green processes[threads]"…
Ivan
  • 7,448
  • 14
  • 69
  • 134
16
votes
2 answers

Erlang Linux signal handling

Is it possible to trap Linux signals (e.g. SIGUSR1) through an handler in Erlang? (without having to resort to a driver crafted in C)
jldupont
  • 93,734
  • 56
  • 203
  • 318
16
votes
3 answers

What profilers and analyzers are there for Erlang/OTP?

Are there any good code profilers/analyzers for Erlang? I need something that can build a call graph (eg gprof) for my code.
Sushant
  • 1,013
  • 1
  • 11
  • 20
16
votes
8 answers

How to create global variables in Erlang

I am writing an ejabberd module to filter packets. I need to get the hostname to pull some configs using gen_mod:get_module_opt(). I have 4 important functions : start(Host, _Opt) : This is an ejabberd function to load my module. I get the Host…
Adil
  • 395
  • 1
  • 5
  • 14
16
votes
4 answers

What is begin...end in Erlang used for?

I just stomped at a begin...end in Erlang's documentation (here), but it doesn't give some examples of how it is useful. Looking here in StackOverflow I found two cases where people would be using begin...end, both in list…
Daniel
  • 21,933
  • 14
  • 72
  • 101