35

I’ve started learning Erlang a few days ago and it’s definitely a very interesting language and very suitable for web development (back end at least). I am going to experiment and eventually settle with one Erlang web framework to use for my next project. Since Erlang is “new” is kind of hard to decide which framework to use (i.e. lack of documentations and blog posts). So far my googleing has returned me 3 results and I am wondering anyone who has experience in Erlang (especially Erlang web development) please comment on the pros and cons on each framework and add any missing frameworks.

Project requirement:

  1. Web application
  2. Database
  3. HTTPs
  4. Storing files (e.g. images)
  5. PDF manipulation
  6. Dynamic logic comparison (e.g. LHS == RHS etc)

Erlang web framework:

  1. Nitrogen (preferred so far)
  2. Erlyweb
  3. BeepBeep
  4. Chicago Boss
  5. Erlang Web
  6. webmachine

Erlang database:

  1. Mnesia (preferred so far)
  2. CouchDb
  3. MongoDB

Concrns:

  1. Nitrogen

    • JavaScript generation

      Since Nitrogen generates and embeddes JavaScript code on to the page which increased the page size. I am not sure if it’s even possible to somehow “separte” the generated JavaScript code from raw html (somehow it can be cached by browser) in order to reduce data transferred down the wire. But I think in general event model and auto wire event is very suitable for application type but not so much for content/public facing type.

Vadim Kotov
  • 8,084
  • 8
  • 48
  • 62
Jeff
  • 13,079
  • 23
  • 71
  • 102
  • 2
    I might have the wrong definition of "Erlang web framework", but Erlang Web and Yaws should also be there. Also there is this new Zotonic CMS, which might be good for you. – Zed Nov 25 '09 at 07:02
  • 2
    Speaking of databases, Mnesia is the only one that you can use as "pure Erlang". Hacking CouchDB to "Erlang only" is non-trivial, and doesn't seem to be their primary target. So you might as well think of all the other new age DBs, such as MongoDB, TokyoCabinet, etc. There is at least two or three Erlang "driver" for each of them. Also, Erlang is equipped with ODBC, so... – Zed Nov 25 '09 at 07:07
  • 2
    I noticed this wasn't mentioned but I came across it - http://www.chicagoboss.org/ – meder omuraliev Nov 25 '09 at 17:28
  • I've seen Chicago Boss a few weeks back while I was googling but somehow the time of writing the question I forgot about it completely! It might be the name of that project that my mind just refuses to think it's a Erlang web framework!!! ^_^ – Jeff Nov 25 '09 at 21:21
  • @Zed, isn't Yaws a web server written in Erlang? Same for MochiWeb. – Jeff Nov 25 '09 at 21:24

5 Answers5

13

This blog post compares a few Erlang web frameworks.

Community
  • 1
  • 1
Vijay Mathew
  • 26,737
  • 4
  • 62
  • 93
6

Personally, I went with mongodb (cos it has native erlang drivers and other advantages) and webmachine for URL dispatching. I like the idea of having very simple wireframe HTML and mostly piping JSON from webmachine and mongodb to the front end to be processed by JQuery or whatever. However, another interesting front end would be cappuccino.

John Galt
  • 257
  • 3
  • 6
  • 1
    I think the future of web development will be front heavy and back heavy. Front heavy means full javaScript client using tools such as SproutCore. Back heavy means an enterprise ready platform such as Erlang. I'm learning Erlang and exploring the web stacks to learn, and here are my choices so far: * JavaScript as the front: thus Nitrogen does not seems a good fit. * Webmachine/Mochiweb: for URL dispatching and web server * ErlyDTL: for HTML templating language * Riak: as the backend database – Gaius Parx Jan 07 '11 at 19:23
3

I'm working with CouchDb. Here is a quick start guide I have written. It is in russian language, but the code samples are clear. I chose this database engine because it was written on Erlang and has a good documentation, samples and libraries on different development languages.

And I'm using BeepBeep, because it is most lightweight framework I have found. Earlyweb is too big for my tasks.

ceth
  • 44,198
  • 62
  • 180
  • 289
  • What's the benefit of CouchDB being "written on Erlang" for you, if you communicate with it over HTTP? – Zed Nov 25 '09 at 07:10
  • 1
    It's pretty good for operations/monitoring to have a "uniform technology stack" (damn, that felt buzzwordy). – Christian Nov 25 '09 at 07:26
  • 1
    And it's easier to understand how it works when I can look at CouchDb source. – ceth Nov 25 '09 at 07:44
  • 1
    Would be good indeed, if you didn't have to run them in separate VMs, using JSON over HTTP to communicate between the two. Also if you look at the CouchDB dependency list, it's far from "uniform" with anything :) – Zed Nov 25 '09 at 07:44
  • I believe Mnesia is written in Erlang. Also I believe Mnesia and Erlang are "unified". www.mdstud.chalmers.se/~md1matso/erlanglinkfaulttolerance.pdf – Jeff Nov 25 '09 at 10:05
0

VoltDB (http://voltdb.com/) is an opensource & commercial database, ACID, scalable, and very high throughput (50x from leading OLTP DBMS). VoltDB recently develops erlang client API, by Henning Deidrich. Just join the forum and find henning.

aris
  • 27
  • 1
-1

As the previous answer stated, VoltDB provides extremely high performance OLTP functionality (transactions and ACID) at scale. There is an Erlang client library available at http://community.voltdb.com/getinvolved#svn

tmcallaghan
  • 1,292
  • 2
  • 10
  • 20