开发者

Common use cases of erlang [closed]

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance. Closed 10 years ago.

What 开发者_Python百科are common use cases of erlang? I know about it in general, but I am looking for specific examples. Are the following some situations where Erlang might be useful?

  1. A distributed Job scheduler. (Take complex multi-staged jobs from a job queue and assign it to worker threads that will perform each thread of it and then pass along the output from one stage to another) (As an aside, this is an interesting case for integrating Erlang and Java/C++. Each Stage might be arbitrarily computationally intensive and hence Erlang might not be appropriate for computation within each step, but might be used to co-ordinate the whole pipeline). (Warning: This looks like Map-reduce, but it is not. There is no reduce operation happening here)
  2. Website Request handling
  3. Distributed algorithm for selecting the Kth largest element among multiple continuous streams of data (or performing such similar analysis)

Somewhere on SO, I read that solving problems on Project Euler using Erlang is a good idea. Is it?

Any other common day-to-day use cases, other than writing erlyweb, couchdb,yaws etc? After seeing applications like Erlyweb, Couchdb, yaws etc. it seems that Erlang mainly shines when you just want to be massively concurrent, but the underlying business logic itself is pretty simple. I dont any famous applications where the business logic is also very complicated as well as needing massive concurrency. Business logic less => they don't do much with the data other than just dispatching it/ passing it/storing it somewhere.

Thanks


Erlang shines at SOA and Server side programming. The complexity of the business logic is not an issue. You can manage as complex of an application as you need. It will be less code than C/C++ and Java for sure to do the same thing, probably less code than Python or Ruby even. There is no constraint on how complex your logic is. I would argue that a telephone switch ( which is what Erlang was first used for ) has some pretty complex statemachines and logic behind it.

It is arguable that functional languages are more expressive and easier to maintain the more complex the logic gets. Erlang is very popular in high volume micro trading applications at BIG banks on Wall Street, the logic on making these trades is way more complex than anything in a common business application.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜