2012/08/15

That Conference: Erlang Goes to Camp!

This session was presented by Bryan Hunter. I figured it’d be interesting to learn more about functional programming in general and how it can interact with .NET more.

  • It’s a functional language
  • Grew out of Prolog
  • Erlang is great at pattern matching
  • OTP (Open Telecom Platform) has libraries, practices and styles)
  • ERTS (Erlang Run-Time System) is more like an OS rather than a VM running on an OS
  • Erlang is open, proven and cross-platform. It simplifies writing reliable, concurrent, distributed systems. Its pattern matching is FTW.
  • On Github
  • Compiled on any platform will run on any other platform
  • Erlang community is more in the Mac & Linux world, but runs great on Windows
  • Erlang supports concurrency very well; especially compared to other languages
  • Concurrency is hard because of sharing state.
  • .NET 4.0 thread allocates 1MB…Erlang Process (Thread) allocates 1KB
  • Distribution was built-in from the start because every process is isolated and everything is done via message passing
  • One Erlang process can essentially watch another process, even on another machine
  • It’s possible to have a true cluster in that there is no master process/node
  • Editing erlang
    • The shell
    • Text editor + command line + shell
  • Every erlang statement is terminated by a period
  • Every variable is upper case
  • Every “atom” is lower case (like function or key word)
  • Lists are defined with []; like L=[100, 200, 5000].
  • Tuples are {}, like Person = {100, “Joe”}.
  • When a node pings another node, it essentially gossips the known nodes to the new one. As soon as nodes know about each other (and the cookies match), there’s full trust to do anything.

No comments: