SlideShare a Scribd company logo
Prolog	
  to	
  Erlang	
  

First	
  version	
  of	
  Erlang	
  was	
  wri2en	
  in	
  
                       Prolog	
  
Examples	
  
hello_mod.erl	
  
1.  -­‐module(hello_mod).	
  
2.  -­‐export([say_hello/0]).	
  

3.  say_hello()	
  -­‐>	
  
4.  	
  	
  	
  	
  io:format("Hello~n",	
  []).	
  
hello_mod:say_hello().	
  
1.  $	
  erl	
  
2.  Erlang	
  R14B04	
  (erts-­‐5.8.5)	
  [source]	
  [64-­‐bit]	
  [smp:4:4]	
  
    [rq:4]	
  [async-­‐threads:0]	
  [hipe]	
  [kernel-­‐poll:false]	
  

3.    Eshell	
  V5.8.5	
  	
  (abort	
  with	
  ^G)	
  
4.    1>	
  c(hello_mod).	
  
5.    {ok,hello_mod}	
  
6.    2>	
  hello_mod:say_hello().	
  
7.    Hello	
  
8.    ok	
  
9.    3>	
  	
  
fact_mod.erl	
  
1.  -­‐module(fact_mod).	
  
2.  -­‐export([fact/1]).	
  

3.  fact(0)	
  -­‐>	
  1;	
  
4.  fact(N)	
  -­‐>	
  N	
  *	
  fact(N	
  -­‐	
  1).	
  
fact_mod:fact(4).	
  
1.  $	
  erl	
  
2.  Erlang	
  R14B04	
  (erts-­‐5.8.5)	
  [source]	
  [64-­‐bit]	
  [smp:4:4]	
  
    [rq:4]	
  [async-­‐threads:0]	
  [hipe]	
  [kernel-­‐poll:false]	
  

3.    Eshell	
  V5.8.5	
  	
  (abort	
  with	
  ^G)	
  
4.    1>	
  c(fact_mod).	
  
5.    {ok,fact_mod}	
  
6.    2>	
  fact_mod:fact(4).	
  
7.    24	
  
8.    3>	
  	
  
qsort_mod.erl	
  
1.  -­‐module(qsort_mod).	
  
2.  -­‐export([qsort/1]).	
  

3.    qsort([])	
  -­‐>	
  
4.    	
  	
  	
  	
  [];	
  
5.    qsort([H	
  |	
  T])	
  -­‐>	
  	
  
6.    	
  	
  	
  	
  qsort([	
  X	
  ||	
  X	
  <-­‐	
  T,	
  X	
  <	
  H	
  ])	
  ++	
  	
  
7.              	
   [H]	
  ++	
  	
  
8.              	
   qsort([	
  X	
  ||	
  X	
  <-­‐	
  T,	
  X	
  >=	
  H	
  ]).	
  
qsort_mod:qsort([3,	
  2,	
  1,	
  6,	
  4,	
  5]).	
  
                      	
  
1.  $	
  erl	
  
2.  Erlang	
  R14B04	
  (erts-­‐5.8.5)	
  [source]	
  [64-­‐bit]	
  [smp:4:4]	
  
    [rq:4]	
  [async-­‐threads:0]	
  [hipe]	
  [kernel-­‐poll:false]	
  

3.    Eshell	
  V5.8.5	
  	
  (abort	
  with	
  ^G)	
  
4.    1>	
  c(qsort_mod).	
  
5.    {ok,qsort_mod}	
  
6.    2>	
  qsort:qsort([3,	
  2,	
  1,	
  6,	
  4,	
  5]).	
  
7.    [1,2,3,4,5,6]	
  
8.    3>	
  	
  
History	
  
§  1986	
  -­‐	
  Joe	
  Armstong	
  (Ericsson)	
  
   §  Prolog	
  
§  1988	
  -­‐	
  Ericsson	
  AXD301	
  ATM	
  telco	
  switch	
  
   §  1	
  million	
  lines	
  of	
  Erlang	
  
   §  99.9999999	
  
§  1995	
  -­‐	
  Open	
  Telecom	
  Plalorm	
  
§  1998	
  -­‐	
  Open	
  source	
  
§  2011	
  -­‐	
  Release	
  14B03	
  
What s	
  Erlang?	
  
Programming	
  Language	
  
§  General-­‐purpose	
  
§  Funcponal	
  	
  
   §  Like	
  LISP,	
  Haskell	
  
§  Garbage-­‐collected	
  
§  Dynamic	
  typing	
  
§  Single	
  assignment	
  
§  Erlang	
  runpme	
  system	
  
   §  STDLIB	
  
Features	
  
§  Massive	
  concurrency	
  and	
  message	
  passing	
  
     §    Actor	
  model	
  
     §    Sos-­‐real-­‐pme	
  
     §    Thousands	
  of	
  processes	
  under	
  single	
  VM	
  
     §    Short	
  GC	
  pauses	
  
§  Distributed	
  
     §  Erlang	
  nodes	
  
§  Fault-­‐tolerant	
  
     §  99.9999999%	
  
§  Powerful	
  error	
  handling	
  
     §  Supervisors	
  
     §  Recovery	
  from	
  errors	
  
§  Non-­‐stop	
  systems	
  
     §  Hot	
  code	
  swapping	
  in	
  producpon	
  
Data	
  types	
  
§  Atoms	
  
     §  open,	
  close,	
  `empty	
  
§  Integers	
  
§  Floats	
  
§  Tuples	
  
     §  {price,	
  12.34}	
  
§  Lists	
  
     §  [1,	
  2,	
  3,	
  4]	
  
§  PIDs	
  
Control	
  Structures	
  
§  Pa2ern	
  matching	
  
§  Guards	
  
§  Higher	
  order	
  funcpons	
  
§  List	
  comprehension	
  
Actors:Message	
  Passing	
  
§  Send	
  message	
  (client	
  process)	
  
   §  ServerProcessId	
  !	
  Message.	
  
§  Receiving	
  a	
  message	
  (server	
  process)	
  
   §  receive	
  
        	
  pa2ern2	
  -­‐>	
  …;	
  
        	
  pa2ern2	
  -­‐>	
  …	
  
       end.	
  
Erlang	
  VM	
  
§  Thousands	
  of	
  processes	
  under	
  single	
  VM	
  
§  Lightweight	
  processes	
  
§  Garbage	
  collecpon	
  per	
  process	
  
§  BEAM	
  files	
  
§  Napve	
  code	
  compiler	
  
Anywhere	
  
§  OS	
  /	
  Hardware	
  independent	
  
   §  UNIX/Linux	
  
   §  Windows	
  
   §  Mac	
  
   §  Embedded	
  
   §  Android	
  
Open	
  Telecom	
  Plalorm	
  

            OTP	
  
OTP	
  Design	
  Principles	
  
§  Supervision	
  trees	
  
    §  Supervisors	
  
    §  Workers	
  
§  Behaviours	
  
    §  gen_server	
  
         §  The	
  server	
  in	
  client-­‐server	
  
    §  fsm_server	
  
         §  Finite	
  state	
  machines	
  
    §  gen_event	
  
         §  Event	
  handling	
  
§  Applicapons	
  
    §  Applicapon	
  
§  Releases	
  
Web	
  Development	
  
Web	
  Development	
  
§  Web	
  Servers	
  
     §  Inets	
  
            §  Build-­‐in	
  
     §  Yaws	
  
            §  80,000	
  concurrent	
  connecpons	
  (2002)	
  
     §  MochiWeb	
  
            §  Lightweight	
  HTTP	
  
§  Web	
  Frameworks	
  
     §  ErlyWeb	
  
            §  MVC	
  for	
  Yaws	
  
     §  Erlang	
  Web	
  
            §  MVC	
  for	
  Yaws	
  and	
  Inets	
  
     §  Nitrogen	
  
            §  An	
  event-­‐driven	
  2.0	
  framework	
  (cometd)	
  
Wri2en	
  in	
  Erlang	
  
§  Apache	
  CouchDB	
  
    §  Document-­‐oriented	
  database	
  (replicapon)	
  
§  RabbitMQ	
  
    §  Message-­‐oriented	
  middleware	
  
§  Riak	
  
    §  NoSQL	
  database	
  (ring)	
  
§  Ejabberd	
  
    §  XMPP	
  applicapon	
  server	
  
Development	
  Tools	
  
§  IDEs	
  
    §  Eclipse	
  
    §  Emacs	
  +	
  Distel	
  
    §  Vim	
  
§  Tools	
  
    §  MOEBIUS	
  
         §  CI	
  Server	
  
    §  rebar	
  
         §  Build	
  and	
  packaging	
  tool	
  
Erlang	
  in	
  Producpon	
  
§  Ericsson	
  AXD301	
  telco	
  switch	
  
     §    160	
  GB/s	
  
     §    1	
  million	
  lines	
  of	
  Erlang	
  
     §    Hundreds	
  of	
  programmers	
  
     §    99.9	
  999	
  999%	
  reliability	
  
§  GPRS	
  
     §  GSM	
  cell	
  telco	
  network	
  
§  Facebook	
  Chat	
  
     §  800+	
  million	
  messages	
  /	
  day	
  
§  GitHub	
  
§  Goldman	
  Sachs	
  ???	
  
     §  High-­‐frequency	
  trading	
  
§  Deutsche	
  Bank	
  

More Related Content

What's hot

Twisted Introduction
Twisted IntroductionTwisted Introduction
Twisted Introduction
cyli
 
Golang Performance : microbenchmarks, profilers, and a war story
Golang Performance : microbenchmarks, profilers, and a war storyGolang Performance : microbenchmarks, profilers, and a war story
Golang Performance : microbenchmarks, profilers, and a war story
Aerospike
 
2014 OSDC Talk: Introduction to Percona XtraDB Cluster and HAProxy
2014 OSDC Talk: Introduction to Percona XtraDB Cluster and HAProxy2014 OSDC Talk: Introduction to Percona XtraDB Cluster and HAProxy
2014 OSDC Talk: Introduction to Percona XtraDB Cluster and HAProxy
Bo-Yi Wu
 
[En] IPVS for Docker Containers
[En] IPVS for Docker Containers[En] IPVS for Docker Containers
[En] IPVS for Docker Containers
Andrey Sibirev
 
Plmce2k15 15 tips galera cluster
Plmce2k15   15 tips galera clusterPlmce2k15   15 tips galera cluster
Plmce2k15 15 tips galera cluster
Frederic Descamps
 
How to monitor NGINX
How to monitor NGINXHow to monitor NGINX
How to monitor NGINX
Server Density
 
Supercharging Content Delivery with Varnish
Supercharging Content Delivery with VarnishSupercharging Content Delivery with Varnish
Supercharging Content Delivery with Varnish
Samantha Quiñones
 
Mасштабирование микросервисов на Go, Matt Heath (Hailo)
Mасштабирование микросервисов на Go, Matt Heath (Hailo)Mасштабирование микросервисов на Go, Matt Heath (Hailo)
Mасштабирование микросервисов на Go, Matt Heath (Hailo)
Ontico
 
Altitude SF 2017: Advanced VCL: Shielding and Clustering
Altitude SF 2017: Advanced VCL: Shielding and ClusteringAltitude SF 2017: Advanced VCL: Shielding and Clustering
Altitude SF 2017: Advanced VCL: Shielding and Clustering
Fastly
 
Rapid Application Design in Financial Services
Rapid Application Design in Financial ServicesRapid Application Design in Financial Services
Rapid Application Design in Financial Services
Aerospike
 
Ceph issue 해결 사례
Ceph issue 해결 사례Ceph issue 해결 사례
Ceph issue 해결 사례
Open Source Consulting
 
How we use Twisted in Launchpad
How we use Twisted in LaunchpadHow we use Twisted in Launchpad
How we use Twisted in Launchpad
Michael Hudson-Doyle
 
Redis And python at pycon_2011
Redis And python at pycon_2011Redis And python at pycon_2011
Redis And python at pycon_2011
sunilar0ra
 
PostgreSQL High-Availability and Geographic Locality using consul
PostgreSQL High-Availability and Geographic Locality using consulPostgreSQL High-Availability and Geographic Locality using consul
PostgreSQL High-Availability and Geographic Locality using consul
Sean Chittenden
 
DIY Java Profiler
DIY Java ProfilerDIY Java Profiler
DIY Java Profiler
aragozin
 
Advanced percona xtra db cluster in a nutshell... la suite plsc2016
Advanced percona xtra db cluster in a nutshell... la suite plsc2016Advanced percona xtra db cluster in a nutshell... la suite plsc2016
Advanced percona xtra db cluster in a nutshell... la suite plsc2016
Frederic Descamps
 
High Availability with Galera Cluster - SkySQL Road Show 2013 in Berlin
High Availability with Galera Cluster - SkySQL Road Show 2013 in BerlinHigh Availability with Galera Cluster - SkySQL Road Show 2013 in Berlin
High Availability with Galera Cluster - SkySQL Road Show 2013 in Berlin
MariaDB Corporation
 
Tales Of The Black Knight - Keeping EverythingMe running
Tales Of The Black Knight - Keeping EverythingMe runningTales Of The Black Knight - Keeping EverythingMe running
Tales Of The Black Knight - Keeping EverythingMe running
Dvir Volk
 
Aaron Mildenstein - Using Logstash with Zabbix
Aaron Mildenstein - Using Logstash with ZabbixAaron Mildenstein - Using Logstash with Zabbix
Aaron Mildenstein - Using Logstash with Zabbix
Zabbix
 
Webinar Slides : Migrating to MySQL, MariaDB Galera and/or Percona XtraDB Clu...
Webinar Slides : Migrating to MySQL, MariaDB Galera and/or Percona XtraDB Clu...Webinar Slides : Migrating to MySQL, MariaDB Galera and/or Percona XtraDB Clu...
Webinar Slides : Migrating to MySQL, MariaDB Galera and/or Percona XtraDB Clu...
Severalnines
 

What's hot (20)

Twisted Introduction
Twisted IntroductionTwisted Introduction
Twisted Introduction
 
Golang Performance : microbenchmarks, profilers, and a war story
Golang Performance : microbenchmarks, profilers, and a war storyGolang Performance : microbenchmarks, profilers, and a war story
Golang Performance : microbenchmarks, profilers, and a war story
 
2014 OSDC Talk: Introduction to Percona XtraDB Cluster and HAProxy
2014 OSDC Talk: Introduction to Percona XtraDB Cluster and HAProxy2014 OSDC Talk: Introduction to Percona XtraDB Cluster and HAProxy
2014 OSDC Talk: Introduction to Percona XtraDB Cluster and HAProxy
 
[En] IPVS for Docker Containers
[En] IPVS for Docker Containers[En] IPVS for Docker Containers
[En] IPVS for Docker Containers
 
Plmce2k15 15 tips galera cluster
Plmce2k15   15 tips galera clusterPlmce2k15   15 tips galera cluster
Plmce2k15 15 tips galera cluster
 
How to monitor NGINX
How to monitor NGINXHow to monitor NGINX
How to monitor NGINX
 
Supercharging Content Delivery with Varnish
Supercharging Content Delivery with VarnishSupercharging Content Delivery with Varnish
Supercharging Content Delivery with Varnish
 
Mасштабирование микросервисов на Go, Matt Heath (Hailo)
Mасштабирование микросервисов на Go, Matt Heath (Hailo)Mасштабирование микросервисов на Go, Matt Heath (Hailo)
Mасштабирование микросервисов на Go, Matt Heath (Hailo)
 
Altitude SF 2017: Advanced VCL: Shielding and Clustering
Altitude SF 2017: Advanced VCL: Shielding and ClusteringAltitude SF 2017: Advanced VCL: Shielding and Clustering
Altitude SF 2017: Advanced VCL: Shielding and Clustering
 
Rapid Application Design in Financial Services
Rapid Application Design in Financial ServicesRapid Application Design in Financial Services
Rapid Application Design in Financial Services
 
Ceph issue 해결 사례
Ceph issue 해결 사례Ceph issue 해결 사례
Ceph issue 해결 사례
 
How we use Twisted in Launchpad
How we use Twisted in LaunchpadHow we use Twisted in Launchpad
How we use Twisted in Launchpad
 
Redis And python at pycon_2011
Redis And python at pycon_2011Redis And python at pycon_2011
Redis And python at pycon_2011
 
PostgreSQL High-Availability and Geographic Locality using consul
PostgreSQL High-Availability and Geographic Locality using consulPostgreSQL High-Availability and Geographic Locality using consul
PostgreSQL High-Availability and Geographic Locality using consul
 
DIY Java Profiler
DIY Java ProfilerDIY Java Profiler
DIY Java Profiler
 
Advanced percona xtra db cluster in a nutshell... la suite plsc2016
Advanced percona xtra db cluster in a nutshell... la suite plsc2016Advanced percona xtra db cluster in a nutshell... la suite plsc2016
Advanced percona xtra db cluster in a nutshell... la suite plsc2016
 
High Availability with Galera Cluster - SkySQL Road Show 2013 in Berlin
High Availability with Galera Cluster - SkySQL Road Show 2013 in BerlinHigh Availability with Galera Cluster - SkySQL Road Show 2013 in Berlin
High Availability with Galera Cluster - SkySQL Road Show 2013 in Berlin
 
Tales Of The Black Knight - Keeping EverythingMe running
Tales Of The Black Knight - Keeping EverythingMe runningTales Of The Black Knight - Keeping EverythingMe running
Tales Of The Black Knight - Keeping EverythingMe running
 
Aaron Mildenstein - Using Logstash with Zabbix
Aaron Mildenstein - Using Logstash with ZabbixAaron Mildenstein - Using Logstash with Zabbix
Aaron Mildenstein - Using Logstash with Zabbix
 
Webinar Slides : Migrating to MySQL, MariaDB Galera and/or Percona XtraDB Clu...
Webinar Slides : Migrating to MySQL, MariaDB Galera and/or Percona XtraDB Clu...Webinar Slides : Migrating to MySQL, MariaDB Galera and/or Percona XtraDB Clu...
Webinar Slides : Migrating to MySQL, MariaDB Galera and/or Percona XtraDB Clu...
 

Viewers also liked

Groovy and Grails
Groovy and GrailsGroovy and Grails
Groovy and Grails
GiltTech
 
Clojure Lightning Talk
Clojure Lightning TalkClojure Lightning Talk
Clojure Lightning Talk
GiltTech
 
Scala for the web Lightning Talk
Scala for the web Lightning TalkScala for the web Lightning Talk
Scala for the web Lightning Talk
GiltTech
 
CoffeeScript Lightning Talk
CoffeeScript Lightning TalkCoffeeScript Lightning Talk
CoffeeScript Lightning Talk
GiltTech
 
Real World Cassandra
Real World CassandraReal World Cassandra
Real World CassandraGiltTech
 
Couchdb at AMEX
Couchdb at AMEXCouchdb at AMEX
Couchdb at AMEXGiltTech
 
Gotszling mogo db-membase
Gotszling mogo db-membaseGotszling mogo db-membase
Gotszling mogo db-membaseGiltTech
 
Riak a successful failure
Riak   a successful failureRiak   a successful failure
Riak a successful failureGiltTech
 
tvOS, The Focus Engine, and Swift
tvOS, The Focus Engine, and SwifttvOS, The Focus Engine, and Swift
tvOS, The Focus Engine, and Swift
Evan Maloney
 

Viewers also liked (9)

Groovy and Grails
Groovy and GrailsGroovy and Grails
Groovy and Grails
 
Clojure Lightning Talk
Clojure Lightning TalkClojure Lightning Talk
Clojure Lightning Talk
 
Scala for the web Lightning Talk
Scala for the web Lightning TalkScala for the web Lightning Talk
Scala for the web Lightning Talk
 
CoffeeScript Lightning Talk
CoffeeScript Lightning TalkCoffeeScript Lightning Talk
CoffeeScript Lightning Talk
 
Real World Cassandra
Real World CassandraReal World Cassandra
Real World Cassandra
 
Couchdb at AMEX
Couchdb at AMEXCouchdb at AMEX
Couchdb at AMEX
 
Gotszling mogo db-membase
Gotszling mogo db-membaseGotszling mogo db-membase
Gotszling mogo db-membase
 
Riak a successful failure
Riak   a successful failureRiak   a successful failure
Riak a successful failure
 
tvOS, The Focus Engine, and Swift
tvOS, The Focus Engine, and SwifttvOS, The Focus Engine, and Swift
tvOS, The Focus Engine, and Swift
 

Similar to Erlang Lightning Talk

Evergreen Sysadmin Survival Skills
Evergreen Sysadmin Survival SkillsEvergreen Sysadmin Survival Skills
Evergreen Sysadmin Survival Skills
Evergreen ILS
 
[OpenStack Days Korea 2016] Track1 - All flash CEPH 구성 및 최적화
[OpenStack Days Korea 2016] Track1 - All flash CEPH 구성 및 최적화[OpenStack Days Korea 2016] Track1 - All flash CEPH 구성 및 최적화
[OpenStack Days Korea 2016] Track1 - All flash CEPH 구성 및 최적화
OpenStack Korea Community
 
introduction to node.js
introduction to node.jsintroduction to node.js
introduction to node.js
orkaplan
 
Strata Singapore: Gearpump Real time DAG-Processing with Akka at Scale
Strata Singapore: GearpumpReal time DAG-Processing with Akka at ScaleStrata Singapore: GearpumpReal time DAG-Processing with Akka at Scale
Strata Singapore: Gearpump Real time DAG-Processing with Akka at Scale
Sean Zhong
 
Rails hosting
Rails hostingRails hosting
Rails hosting
wonko
 
AsiaBSDCon2023 - Hardening Emulated Devices in OpenBSD’s vmd(8) Hypervisor
AsiaBSDCon2023 - Hardening Emulated Devices in OpenBSD’s vmd(8) HypervisorAsiaBSDCon2023 - Hardening Emulated Devices in OpenBSD’s vmd(8) Hypervisor
AsiaBSDCon2023 - Hardening Emulated Devices in OpenBSD’s vmd(8) Hypervisor
Dave Voutila
 
"How about no grep and zabbix?". ELK based alerts and metrics.
"How about no grep and zabbix?". ELK based alerts and metrics."How about no grep and zabbix?". ELK based alerts and metrics.
"How about no grep and zabbix?". ELK based alerts and metrics.
Vladimir Pavkin
 
End to End Processing of 3.7 Million Telemetry Events per Second using Lambda...
End to End Processing of 3.7 Million Telemetry Events per Second using Lambda...End to End Processing of 3.7 Million Telemetry Events per Second using Lambda...
End to End Processing of 3.7 Million Telemetry Events per Second using Lambda...
DataWorks Summit/Hadoop Summit
 
Linked Process
Linked ProcessLinked Process
Linked Process
Joshua Shinavier
 
Oracle GoldenGate Architecture Performance
Oracle GoldenGate Architecture PerformanceOracle GoldenGate Architecture Performance
Oracle GoldenGate Architecture PerformanceEnkitec
 
Next Generation DevOps in Drupal: DrupalCamp London 2014
Next Generation DevOps in Drupal: DrupalCamp London 2014Next Generation DevOps in Drupal: DrupalCamp London 2014
Next Generation DevOps in Drupal: DrupalCamp London 2014
Barney Hanlon
 
Netflix Global Applications - NoSQL Search Roadshow
Netflix Global Applications - NoSQL Search RoadshowNetflix Global Applications - NoSQL Search Roadshow
Netflix Global Applications - NoSQL Search Roadshow
Adrian Cockcroft
 
Evented Ruby VS Node.js
Evented Ruby VS Node.jsEvented Ruby VS Node.js
Evented Ruby VS Node.js
Nitin Gupta
 
Ingesting hdfs intosolrusingsparktrimmed
Ingesting hdfs intosolrusingsparktrimmedIngesting hdfs intosolrusingsparktrimmed
Ingesting hdfs intosolrusingsparktrimmed
whoschek
 
Elixir Into Production
Elixir Into ProductionElixir Into Production
Elixir Into Production
Jamie Winsor
 
Egearmand: an Erlang Gearman daemon
Egearmand: an Erlang Gearman daemonEgearmand: an Erlang Gearman daemon
Egearmand: an Erlang Gearman daemon
Antonio Garrote Hernández
 
%w(map reduce).first - A Tale About Rabbits, Latency, and Slim Crontabs
%w(map reduce).first - A Tale About Rabbits, Latency, and Slim Crontabs%w(map reduce).first - A Tale About Rabbits, Latency, and Slim Crontabs
%w(map reduce).first - A Tale About Rabbits, Latency, and Slim Crontabs
Paolo Negri
 
Going to Mars with Groovy Domain-Specific Languages
Going to Mars with Groovy Domain-Specific LanguagesGoing to Mars with Groovy Domain-Specific Languages
Going to Mars with Groovy Domain-Specific Languages
Guillaume Laforge
 
De Java 8 ate Java 14
De Java 8 ate Java 14De Java 8 ate Java 14
De Java 8 ate Java 14
Víctor Leonel Orozco López
 
OGG Architecture Performance
OGG Architecture PerformanceOGG Architecture Performance
OGG Architecture PerformanceEnkitec
 

Similar to Erlang Lightning Talk (20)

Evergreen Sysadmin Survival Skills
Evergreen Sysadmin Survival SkillsEvergreen Sysadmin Survival Skills
Evergreen Sysadmin Survival Skills
 
[OpenStack Days Korea 2016] Track1 - All flash CEPH 구성 및 최적화
[OpenStack Days Korea 2016] Track1 - All flash CEPH 구성 및 최적화[OpenStack Days Korea 2016] Track1 - All flash CEPH 구성 및 최적화
[OpenStack Days Korea 2016] Track1 - All flash CEPH 구성 및 최적화
 
introduction to node.js
introduction to node.jsintroduction to node.js
introduction to node.js
 
Strata Singapore: Gearpump Real time DAG-Processing with Akka at Scale
Strata Singapore: GearpumpReal time DAG-Processing with Akka at ScaleStrata Singapore: GearpumpReal time DAG-Processing with Akka at Scale
Strata Singapore: Gearpump Real time DAG-Processing with Akka at Scale
 
Rails hosting
Rails hostingRails hosting
Rails hosting
 
AsiaBSDCon2023 - Hardening Emulated Devices in OpenBSD’s vmd(8) Hypervisor
AsiaBSDCon2023 - Hardening Emulated Devices in OpenBSD’s vmd(8) HypervisorAsiaBSDCon2023 - Hardening Emulated Devices in OpenBSD’s vmd(8) Hypervisor
AsiaBSDCon2023 - Hardening Emulated Devices in OpenBSD’s vmd(8) Hypervisor
 
"How about no grep and zabbix?". ELK based alerts and metrics.
"How about no grep and zabbix?". ELK based alerts and metrics."How about no grep and zabbix?". ELK based alerts and metrics.
"How about no grep and zabbix?". ELK based alerts and metrics.
 
End to End Processing of 3.7 Million Telemetry Events per Second using Lambda...
End to End Processing of 3.7 Million Telemetry Events per Second using Lambda...End to End Processing of 3.7 Million Telemetry Events per Second using Lambda...
End to End Processing of 3.7 Million Telemetry Events per Second using Lambda...
 
Linked Process
Linked ProcessLinked Process
Linked Process
 
Oracle GoldenGate Architecture Performance
Oracle GoldenGate Architecture PerformanceOracle GoldenGate Architecture Performance
Oracle GoldenGate Architecture Performance
 
Next Generation DevOps in Drupal: DrupalCamp London 2014
Next Generation DevOps in Drupal: DrupalCamp London 2014Next Generation DevOps in Drupal: DrupalCamp London 2014
Next Generation DevOps in Drupal: DrupalCamp London 2014
 
Netflix Global Applications - NoSQL Search Roadshow
Netflix Global Applications - NoSQL Search RoadshowNetflix Global Applications - NoSQL Search Roadshow
Netflix Global Applications - NoSQL Search Roadshow
 
Evented Ruby VS Node.js
Evented Ruby VS Node.jsEvented Ruby VS Node.js
Evented Ruby VS Node.js
 
Ingesting hdfs intosolrusingsparktrimmed
Ingesting hdfs intosolrusingsparktrimmedIngesting hdfs intosolrusingsparktrimmed
Ingesting hdfs intosolrusingsparktrimmed
 
Elixir Into Production
Elixir Into ProductionElixir Into Production
Elixir Into Production
 
Egearmand: an Erlang Gearman daemon
Egearmand: an Erlang Gearman daemonEgearmand: an Erlang Gearman daemon
Egearmand: an Erlang Gearman daemon
 
%w(map reduce).first - A Tale About Rabbits, Latency, and Slim Crontabs
%w(map reduce).first - A Tale About Rabbits, Latency, and Slim Crontabs%w(map reduce).first - A Tale About Rabbits, Latency, and Slim Crontabs
%w(map reduce).first - A Tale About Rabbits, Latency, and Slim Crontabs
 
Going to Mars with Groovy Domain-Specific Languages
Going to Mars with Groovy Domain-Specific LanguagesGoing to Mars with Groovy Domain-Specific Languages
Going to Mars with Groovy Domain-Specific Languages
 
De Java 8 ate Java 14
De Java 8 ate Java 14De Java 8 ate Java 14
De Java 8 ate Java 14
 
OGG Architecture Performance
OGG Architecture PerformanceOGG Architecture Performance
OGG Architecture Performance
 

Recently uploaded

Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Paige Cruz
 
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
名前 です男
 
GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...
ThomasParaiso2
 
Large Language Model (LLM) and it’s Geospatial Applications
Large Language Model (LLM) and it’s Geospatial ApplicationsLarge Language Model (LLM) and it’s Geospatial Applications
Large Language Model (LLM) and it’s Geospatial Applications
Rohit Gautam
 
Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?
Nexer Digital
 
Removing Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software FuzzingRemoving Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software Fuzzing
Aftab Hussain
 
UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5
DianaGray10
 
RESUME BUILDER APPLICATION Project for students
RESUME BUILDER APPLICATION Project for studentsRESUME BUILDER APPLICATION Project for students
RESUME BUILDER APPLICATION Project for students
KAMESHS29
 
20240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 202420240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 2024
Matthew Sinclair
 
Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
Alan Dix
 
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
Neo4j
 
20 Comprehensive Checklist of Designing and Developing a Website
20 Comprehensive Checklist of Designing and Developing a Website20 Comprehensive Checklist of Designing and Developing a Website
20 Comprehensive Checklist of Designing and Developing a Website
Pixlogix Infotech
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
Kari Kakkonen
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
James Anderson
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
Safe Software
 
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdfFIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance
 
Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1
DianaGray10
 
GraphSummit Singapore | The Art of the Possible with Graph - Q2 2024
GraphSummit Singapore | The Art of the  Possible with Graph - Q2 2024GraphSummit Singapore | The Art of the  Possible with Graph - Q2 2024
GraphSummit Singapore | The Art of the Possible with Graph - Q2 2024
Neo4j
 
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
Neo4j
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
Quotidiano Piemontese
 

Recently uploaded (20)

Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
 
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
 
GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...
 
Large Language Model (LLM) and it’s Geospatial Applications
Large Language Model (LLM) and it’s Geospatial ApplicationsLarge Language Model (LLM) and it’s Geospatial Applications
Large Language Model (LLM) and it’s Geospatial Applications
 
Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?Elizabeth Buie - Older adults: Are we really designing for our future selves?
Elizabeth Buie - Older adults: Are we really designing for our future selves?
 
Removing Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software FuzzingRemoving Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software Fuzzing
 
UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5UiPath Test Automation using UiPath Test Suite series, part 5
UiPath Test Automation using UiPath Test Suite series, part 5
 
RESUME BUILDER APPLICATION Project for students
RESUME BUILDER APPLICATION Project for studentsRESUME BUILDER APPLICATION Project for students
RESUME BUILDER APPLICATION Project for students
 
20240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 202420240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 2024
 
Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
 
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
 
20 Comprehensive Checklist of Designing and Developing a Website
20 Comprehensive Checklist of Designing and Developing a Website20 Comprehensive Checklist of Designing and Developing a Website
20 Comprehensive Checklist of Designing and Developing a Website
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
 
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdfFIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
FIDO Alliance Osaka Seminar: The WebAuthn API and Discoverable Credentials.pdf
 
Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1
 
GraphSummit Singapore | The Art of the Possible with Graph - Q2 2024
GraphSummit Singapore | The Art of the  Possible with Graph - Q2 2024GraphSummit Singapore | The Art of the  Possible with Graph - Q2 2024
GraphSummit Singapore | The Art of the Possible with Graph - Q2 2024
 
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
 

Erlang Lightning Talk

  • 1. Prolog  to  Erlang   First  version  of  Erlang  was  wri2en  in   Prolog  
  • 3. hello_mod.erl   1.  -­‐module(hello_mod).   2.  -­‐export([say_hello/0]).   3.  say_hello()  -­‐>   4.         io:format("Hello~n",  []).  
  • 4. hello_mod:say_hello().   1.  $  erl   2.  Erlang  R14B04  (erts-­‐5.8.5)  [source]  [64-­‐bit]  [smp:4:4]   [rq:4]  [async-­‐threads:0]  [hipe]  [kernel-­‐poll:false]   3.  Eshell  V5.8.5    (abort  with  ^G)   4.  1>  c(hello_mod).   5.  {ok,hello_mod}   6.  2>  hello_mod:say_hello().   7.  Hello   8.  ok   9.  3>    
  • 5. fact_mod.erl   1.  -­‐module(fact_mod).   2.  -­‐export([fact/1]).   3.  fact(0)  -­‐>  1;   4.  fact(N)  -­‐>  N  *  fact(N  -­‐  1).  
  • 6. fact_mod:fact(4).   1.  $  erl   2.  Erlang  R14B04  (erts-­‐5.8.5)  [source]  [64-­‐bit]  [smp:4:4]   [rq:4]  [async-­‐threads:0]  [hipe]  [kernel-­‐poll:false]   3.  Eshell  V5.8.5    (abort  with  ^G)   4.  1>  c(fact_mod).   5.  {ok,fact_mod}   6.  2>  fact_mod:fact(4).   7.  24   8.  3>    
  • 7. qsort_mod.erl   1.  -­‐module(qsort_mod).   2.  -­‐export([qsort/1]).   3.  qsort([])  -­‐>   4.         [];   5.  qsort([H  |  T])  -­‐>     6.         qsort([  X  ||  X  <-­‐  T,  X  <  H  ])  ++     7.    [H]  ++     8.    qsort([  X  ||  X  <-­‐  T,  X  >=  H  ]).  
  • 8. qsort_mod:qsort([3,  2,  1,  6,  4,  5]).     1.  $  erl   2.  Erlang  R14B04  (erts-­‐5.8.5)  [source]  [64-­‐bit]  [smp:4:4]   [rq:4]  [async-­‐threads:0]  [hipe]  [kernel-­‐poll:false]   3.  Eshell  V5.8.5    (abort  with  ^G)   4.  1>  c(qsort_mod).   5.  {ok,qsort_mod}   6.  2>  qsort:qsort([3,  2,  1,  6,  4,  5]).   7.  [1,2,3,4,5,6]   8.  3>    
  • 9. History   §  1986  -­‐  Joe  Armstong  (Ericsson)   §  Prolog   §  1988  -­‐  Ericsson  AXD301  ATM  telco  switch   §  1  million  lines  of  Erlang   §  99.9999999   §  1995  -­‐  Open  Telecom  Plalorm   §  1998  -­‐  Open  source   §  2011  -­‐  Release  14B03  
  • 11. Programming  Language   §  General-­‐purpose   §  Funcponal     §  Like  LISP,  Haskell   §  Garbage-­‐collected   §  Dynamic  typing   §  Single  assignment   §  Erlang  runpme  system   §  STDLIB  
  • 12. Features   §  Massive  concurrency  and  message  passing   §  Actor  model   §  Sos-­‐real-­‐pme   §  Thousands  of  processes  under  single  VM   §  Short  GC  pauses   §  Distributed   §  Erlang  nodes   §  Fault-­‐tolerant   §  99.9999999%   §  Powerful  error  handling   §  Supervisors   §  Recovery  from  errors   §  Non-­‐stop  systems   §  Hot  code  swapping  in  producpon  
  • 13. Data  types   §  Atoms   §  open,  close,  `empty   §  Integers   §  Floats   §  Tuples   §  {price,  12.34}   §  Lists   §  [1,  2,  3,  4]   §  PIDs  
  • 14. Control  Structures   §  Pa2ern  matching   §  Guards   §  Higher  order  funcpons   §  List  comprehension  
  • 15. Actors:Message  Passing   §  Send  message  (client  process)   §  ServerProcessId  !  Message.   §  Receiving  a  message  (server  process)   §  receive    pa2ern2  -­‐>  …;    pa2ern2  -­‐>  …   end.  
  • 16. Erlang  VM   §  Thousands  of  processes  under  single  VM   §  Lightweight  processes   §  Garbage  collecpon  per  process   §  BEAM  files   §  Napve  code  compiler  
  • 17. Anywhere   §  OS  /  Hardware  independent   §  UNIX/Linux   §  Windows   §  Mac   §  Embedded   §  Android  
  • 19. OTP  Design  Principles   §  Supervision  trees   §  Supervisors   §  Workers   §  Behaviours   §  gen_server   §  The  server  in  client-­‐server   §  fsm_server   §  Finite  state  machines   §  gen_event   §  Event  handling   §  Applicapons   §  Applicapon   §  Releases  
  • 21. Web  Development   §  Web  Servers   §  Inets   §  Build-­‐in   §  Yaws   §  80,000  concurrent  connecpons  (2002)   §  MochiWeb   §  Lightweight  HTTP   §  Web  Frameworks   §  ErlyWeb   §  MVC  for  Yaws   §  Erlang  Web   §  MVC  for  Yaws  and  Inets   §  Nitrogen   §  An  event-­‐driven  2.0  framework  (cometd)  
  • 22. Wri2en  in  Erlang   §  Apache  CouchDB   §  Document-­‐oriented  database  (replicapon)   §  RabbitMQ   §  Message-­‐oriented  middleware   §  Riak   §  NoSQL  database  (ring)   §  Ejabberd   §  XMPP  applicapon  server  
  • 23. Development  Tools   §  IDEs   §  Eclipse   §  Emacs  +  Distel   §  Vim   §  Tools   §  MOEBIUS   §  CI  Server   §  rebar   §  Build  and  packaging  tool  
  • 24. Erlang  in  Producpon   §  Ericsson  AXD301  telco  switch   §  160  GB/s   §  1  million  lines  of  Erlang   §  Hundreds  of  programmers   §  99.9  999  999%  reliability   §  GPRS   §  GSM  cell  telco  network   §  Facebook  Chat   §  800+  million  messages  /  day   §  GitHub   §  Goldman  Sachs  ???   §  High-­‐frequency  trading   §  Deutsche  Bank