The Erlang Interoperability Guide discusses various interoperability mechanisms. Here are my findings:
Ports and programs Erl_Interface: planned OS, scalability along borders.
Port driver: It is dangerous because an accident in the port driver brings an emulator too.
C Nodes: The Node server must scale, as well as the Erlang application, to avoid the sacrifice of scalability.
NIF: Loic sums them well.
Some advocate using OpenCL primarily to delegate resource hungry computing to the GPU, allowing the Erlang emulator to own the processor. It sounds fantastic, but then you have a requirement on your servers with a suitable GPU.
Using a JInterface and linking to a Java process that spawns a thread for each request may be an option.
So, did anyone come across a solution that was tested in practice and turned out to work well?
source
share