Erlang: Bult for concurrent, distributed systems


Published on

Quick overview of Erlang presented to the Vancouver Graph Database meetup on July 27, 2011.

Published in: Technology, News & Politics
1 Like
  • Be the first to comment

No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide

Erlang: Bult for concurrent, distributed systems

  1. 1. Erlang Built for concurrent, distributed systems July 27, 2011 Ken Pratt, July 27, 2011
  2. 2. The philosophy "Erlang was designed for writing concurrent programs that "run forever"" - Joe ArmstrongWednesday, July 27, 2011
  3. 3. The philosophy Simple language Ultra-lightweight concurrency No shared state Local & remote communication via messagingWednesday, July 27, 2011
  4. 4. The language Functional Pattern matching No variables! (well, they don’t vary, anyway) Compiled to bytecode, runs on VMWednesday, July 27, 2011
  5. 5. The VM Processes Pre-emptive scheduler Memory manager Mesh networkingWednesday, July 27, 2011
  6. 6. Erlang == distributed OS? Erlang is not so much a programming language as it is a distributed Operating System. It’s like an ant colony with thousands of ants performing all sorts of different tasks. Erlang is to threads what garbage collection is to manual memory management -- it brings concurrent programming into the 21st century.Wednesday, July 27, 2011
  7. 7. Local architecture = light-weight process with a built-in mailboxWednesday, July 27, 2011
  8. 8. Distributed architecture = light-weight process with a built-in mailboxWednesday, July 27, 2011
  9. 9. Interesting architectures Having thousands of lightweight “threads” really opens up the architecture options. The main example application on the “Erlang and OTP in Action” book is a cache using one process per cache entry!Wednesday, July 27, 2011
  10. 10. Standard library Common patterns do all the concurrency heavy lifting for you (gen_server, rpc) Supervision trees Hot code deploymentWednesday, July 27, 2011
  11. 11. In production Chat backend SimpleDB Orchestration of Ruby services Routing mesh, logging systemWednesday, July 27, 2011
  12. 12. Erlang + Neo4j Erlang has graphs: digraph.html BUT, it’s no Graph DBWednesday, July 27, 2011
  13. 13. Erlang + Neo4j Nerlo: (Jinterface-based) Cali: (Jinterface-based) Both look pretty dead-in-the-water (no commits on either project in ~1 yr) BUT, Jinterface works well, so does Mule ESB. So in the worst case you could write your Neo4j adapters in the JVM and bridge to Erlang with a biz-logic-level API.Wednesday, July 27, 2011
  14. 14. ResourcesWednesday, July 27, 2011