TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Ask: Is anyone else using Erlang?

5 点作者 ncarlson超过 16 年前
Hey guys,<p>I've decided to use erlang for my next project. I'm in need of a solution that has massive parallelism (thousands of threads) and works over a geographically distributed system. From what I've read, erlang is the way to go.<p>The syntax is kind of wonky, but it only took me about a day to get used to. Erlang is my first functional language though, so I'm still trying to get into the swing of functional thinking.

2 条评论

kriyative超过 16 年前
I used Erlang to build a mid-sized web service app (i.e. REST only, no user interface) which serves more than two million connections per day (sustained), and is deployed on a half dozen nodes across the Internet -- different ISPs (yeah, I'm a masochist). The app integrates the Mnesia database (with replication) and the Yaws web server (with my own extensions).<p>On any given node there were between 1,000 and 3,000 processes (threads) handling requests and internal jobs. I had supervisor trees for ensuring that everything kept running. All that worked like a charm.<p>Most of the issues I ran into were with getting the host infrastructure (Linux in my case) configured correctly. Things like number of available socket handles etc. Erlang dies unceremoniously when it runs out of system resources.<p>Mnesia is really nice. My database isn't very big (~500K objects), but still needed to be redundant and highly available. Setting all that was a breeze compared to most SQL dbs.<p>Yaws is nice, in that it's a full featured web server, but I'd probably also look at Mochiweb (<a href="http://bob.pythonmac.org/archives/2007/11/07/mochiweb-another-faster-web-server/" rel="nofollow">http://bob.pythonmac.org/archives/2007/11/07/mochiweb-anothe...</a>).<p>Given that you have a requirement for "massive parallelism" -- high concurrency, Erlang is a very good option. I also believe Scala (<a href="http://debasishg.blogspot.com/2006/11/threadless-concurrency-on-jvm-aka-scala.html" rel="nofollow">http://debasishg.blogspot.com/2006/11/threadless-concurrency...</a>) and Clojure (<a href="http://clojure.org/concurrent_programming" rel="nofollow">http://clojure.org/concurrent_programming</a>) offer reasonable alternate approaches.<p>Good luck.
qhoxie超过 16 年前
Without any more details than you are <i>"in need of a solution that has massive parallelism,"</i> I would say erlang is a good route.<p>Lots of people use erlang for mission-critical systems. Implemented correctly, it is likely to be a good choice.