开发者

Actor-based distributed concurrency libraries for Ocaml and other languages [closed]

开发者 https://www.devze.com 2023-04-07 16:13 出处:网络
Closed. This question is seeking recommendations for books, tools, software libraries, and more. It does not meet Stack Overflow guidelines. It is not currently accepting answers.开发者_如何学JAVA
Closed. This question is seeking recommendations for books, tools, software libraries, and more. It does not meet Stack Overflow guidelines. It is not currently accepting answers. 开发者_如何学JAVA

We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.

Closed 3 years ago.

Improve this question

Question

Can anyone recommend a library for Ocaml that offers an actor-based concurrency model for distributed computing?

Note here the "actor-based" and "distributed" - I'd like the actor-based model, but also I want seamless handling of distributed actors - I don't want to write the protocol to talk to them. The library should ideally also offer standard patterns such a supervisor trees and so on.


Motivation

I love Erlang concurrency model and ability to transparently deal with distributed processes and local processes together. However, I find Erlang's syntax to be rather limiting and would like a much more expressive language. I'm considering moving from Erlang to either Scala or Ocaml.

I know Scala has the Akka library which seems to offer a nice Scala version of Erlang's concurrency model. I'd like to see what is available on the Ocaml side.


Aside

I'd also be happy to hear about actor-based concurrency libraries for other languages (particularly C++, Haskell, Python and Ruby).


While it may not be the exact same model that Erlang uses, you might want to take a look at JoCaml, which is based on the join calculus.


You can take a look at parvel -- message passing library/framework for ocaml. It's not yet complete, but already includes some primitives for programming with actors.


"I'm considering moving from Erlang to either Scala or Ocaml."

You should consider scalang, which allows you to program in Scala, but use Erlang's actors.

I recently saw a talk on the language by @moonpolysoft (Cliff Moon) at the Strange Loop conference. Cliff Moon developed it for https://boundary.com/ and open-sourced it earlier this year.


You'll probably spend a lot of time reading about:

Scala and F# have akka and MailboxProcessor which are being used in production apps (note: Scala actors and, I think, akka, are very tied to Hotspot; I'm not sure if MailboxProcessor can be used under MONO)

Haskell has userspace threads and at least 1 actor implementation which i don't know a lot about

For ML and ocaml, some libs which are probably not widely used: poly/ML and oc4mc

and netmulticore


Although, it is a very old question things have changed since it was asked. C++ has an actor model implementation which is quite robust. It also provides distributed computing features as asked by OP. The homepage is at http://actor-framework.org/

Further, it can also make us of OpenCL for HPC the module for which is located at github in one of the repositories.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号