3 ms·
I think for Scala and Clojure it does not make sense to equalize the languages with a single concurrency model, as they both build on the JVM and provide severa
by Matthias247 11y ago
I think for Scala and Clojure it does not make sense to equalize the languages with a single concurrency model, as they both build on the JVM and provide several libraries and approaches to concurrency. Scala has quite a lot of different actor implementations (std library, scalaz, akka, etc.), clojure has multiple ways (Atoms, Agents, STM, core.async) and you could even use plain java threads with mutexes or lockless data structures or green threads with Quasar/Pulsar on both.
Erlang makes it at least easier to choose a way to solve the problem, because it does not give you that much possibilities :) Erlang concurrency is probably a mix between Scala/Akka actors (unbounded queues, you send things to actors/processes, not to mailboxes) and clojure core.async (you can block inside the actor process).
The 7 concurrency models in 7 weeks book talks about all of those a little bit in case you are more interested in this topic.