Erlang Programming Language - Computerphile

แชร์
ฝัง
  • เผยแพร่เมื่อ 16 ธ.ค. 2019
  • Introducing Erlang - with Francesco Cesarini Technical Director of Erlang Solutions.
    / computerphile
    / computer_phile
    This video was filmed and edited by Sean Riley.
    Computer Science at the University of Nottingham: bit.ly/nottscomputer
    Computerphile is a sister project to Brady Haran's Numberphile. More at www.bradyharan.com

ความคิดเห็น • 440

  • @linz4213
    @linz4213 4 ปีที่แล้ว +282

    The animation for pattern matching and recursion is major milestone in computer science education

    • @patternwhisperer4048
      @patternwhisperer4048 4 ปีที่แล้ว +4

      ... I mean ive seen animations similar to it in my undergrad several years ago already

    • @Oladipupo_
      @Oladipupo_ 4 ปีที่แล้ว +12

      @@patternwhisperer4048 My man I never did, I had to visual myself, I was lucky that I had it easy

    • @custardtart1312
      @custardtart1312 2 ปีที่แล้ว +7

      @@patternwhisperer4048 I saw it as an embryo in 1971

    • @goodtechdoor
      @goodtechdoor 7 หลายเดือนก่อน

      Epic !

  • @leedeffebach3504
    @leedeffebach3504 4 ปีที่แล้ว +223

    Haven't done erlang but just recently learned elixir. Elixir is erlangs child basically. It's awesome, if you haven't tried it yet try it now.

    • @elliott8175
      @elliott8175 3 ปีที่แล้ว +47

      So when Elixir crashes then Erlang gets a notification? =P

    • @Nehpets94
      @Nehpets94 3 ปีที่แล้ว +9

      It's a BEAM language. There's a lot of them, but I think Elixir is probably going to be the one to push this paradigm forward.

    • @dandan7884
      @dandan7884 3 ปีที่แล้ว

      @@Nehpets94 like ruby

    • @rickhackro
      @rickhackro 2 ปีที่แล้ว

      I was already tempted...

    • @stnhld2841
      @stnhld2841 2 ปีที่แล้ว +6

      RabbitMQ is written in Erlang. Elixir is very cool.

  • @shotovar
    @shotovar 4 ปีที่แล้ว +56

    I met this man at ElixirConfLA 2019, I've gotta say he is a genius in terms of Erlang.

    • @cat47
      @cat47 5 หลายเดือนก่อน

      did i ask?

  • @mellertid
    @mellertid 2 ปีที่แล้ว +51

    Ericsson really made impressive progress all over Telecom, from mechanical switch modules through Erlang to Bluetooth.

  • @armin_hammer_studios
    @armin_hammer_studios 4 ปีที่แล้ว +33

    Absolutely love Erlang and all of the material Joe Armstrong has online. Anybody interested in computer science in general should watch Joe's online talks.
    RIP Joe, you are a hero to me and countless others.

  • @kalebbruwer
    @kalebbruwer 4 ปีที่แล้ว +292

    So it's encouraged to skip error checking?
    _I was born for this_

    • @lpil
      @lpil 4 ปีที่แล้ว +68

      You are encouraged to check for _expected_ errors. Unexpected errors are to be handled non-locally, though design of your supervision tree. The reality of Erlang programming is that you spend more time than average thinking about error and failure, but it obscures your business logic less, and your code is more reliable.

    • @IIARROWS
      @IIARROWS 4 ปีที่แล้ว +2

      If you are a bad programmer, you can do that on every programming language.
      Don't be an asshole.

    • @whossname4399
      @whossname4399 4 ปีที่แล้ว +14

      @@lpil I feel this is something that needs to be made more explicit to beginers. It took me a while to figure out what 'let it crash' actually meant.

    • @whossname4399
      @whossname4399 4 ปีที่แล้ว +9

      @@IIARROWS if you think he was being an asshole you probably don't understand what he is saying. The language design encourages you to think about the system behaviour for your error conditions while also reducing the amount of code you write for handling those errors.

    • @mikew2229
      @mikew2229 4 ปีที่แล้ว +2

      Erlang OTP has the concept of supervisor that monitor and restart its process if one is crashed. Over catching errors usually makes life very hard to locate the real line of bug code is.

  • @StickySli
    @StickySli 3 ปีที่แล้ว +63

    I'm starting to love this language more each day.
    On the other hand, my teacher handed us an assignment to make an industrial elevator lift (without doors or human safety checks) simulation through Erlang.
    It is quite easy to wrap your head around this problem:
    The elevator requires a motor, the motor can only go at one speed in two directions and can only sense when it reaches the top or bottom.
    The elevator also requires a single sensor for each floor. Basically, each sensor is its own process, and talks to a supervisor which then talks to the motor.
    The elevator also requires a button cabinet. Imagine that each button when pressed, sens a signal, to the elevator master supervisor. Then, the master supervisor can light on or off the button. There is also a display because why not.
    The motor is easy to implement with a finite-state machine, and the master sensor will have to distribute its slave sensors.
    Can you see now? With what you learned from this video it is quite simple to get a grasp on how the process tree looks like. Erlang is so fun!

    • @brainless3651
      @brainless3651 3 ปีที่แล้ว +1

      Nice

    • @ruhtam8971
      @ruhtam8971 2 ปีที่แล้ว +3

      Please share the solution in github and link it here if you can spare some time. I want to learn this too

    • @StickySli
      @StickySli 2 ปีที่แล้ว +5

      @@ruhtam8971 Since this lab work was handed to my teacher, it is now the university intellectual property and I cannot post the solution. I will have to ask my teacher if I'm allowed to share the code. He will most likely say no to my question because it was the last project for this course and other students might plagiarize my own work. I hope you understand my situation.

    • @ruhtam8971
      @ruhtam8971 2 ปีที่แล้ว +2

      @@StickySli okay then I'll attempt a solution on my own taking inspiration from your explanations. Thank you

    • @StickySli
      @StickySli 2 ปีที่แล้ว +1

      @@ruhtam8971 You should start with "P1" if you are a newbie to Erlang. The difficulty increases quite a lot afterwards, specially with the other lab works. I hope you have a great day sir!

  • @Anaximander29A
    @Anaximander29A 4 ปีที่แล้ว +42

    We had to use this language in university to write algorithms and datastructures. At first I was like wtf, but then after a while I really started to dig it.
    The ability to write implicit if-cases just with function headers makes it very elegant imo.

    • @NaumRusomarov
      @NaumRusomarov 4 ปีที่แล้ว +2

      Fun fact. You can in theory just use case- and if-statements for flow control without even touching pattern matching in the function headers, but the code very quickly becomes unwieldy because of the static variables; (recursive) loops done like this are quite hilarious. It's a fun exercise to see how far you can push the language by limiting some of its features.

    • @AndersJackson
      @AndersJackson 4 ปีที่แล้ว +5

      First Erlang was written in Prolog, so that was the part that came from Prolog.

  • @caw25sha
    @caw25sha 4 ปีที่แล้ว +21

    I worked on a system written in C# with 120 threads (don't ask!) and Erlang would have been brilliant for that. Great video.

  • @KlojoVidjo
    @KlojoVidjo 4 ปีที่แล้ว +47

    Douglas Adams:
    Click, click, hum.
    Click, hum, click, hum, click, hum.
    Click, click, click, click, click, hum.
    Hmmm.
    A low level supervising program woke up a slightly higher level supervising program deep in the ship's semi-somnolent cyberbrain and reported to it that whenever it went click all it got was a hum.
    The higher level supervising program asked it what it was supposed to get, and the low level supervising program said that it couldn't remember exactly, but thought it was probably more of a sort of distant satisfied sigh, wasn't it? It didn't know what this hum was. Click, hum, click, hum. That was all it was getting.
    The higher level supervising program considered this and didn't like it. It asked the low level supervising program what exactly it was supervising and the low level supervising program said it couldn't remember that either, just that it was something that was meant to go click, sigh every ten years or so, which usually happened without fail. It had tried to consult its error look-up table but couldn't find it, which was why it had alerted the higher level supervising program to the problem.
    The higher level supervising program went to consult one of its own look-up tables to find out what the low level supervising program was meant to be supervising.
    It couldn't find the look-up table.
    Odd.

  • @contingenceBoston
    @contingenceBoston 4 ปีที่แล้ว +138

    This is surprisingly easy to wrap one's head around. Rad.

    • @hauleth
      @hauleth 4 ปีที่แล้ว +14

      At its core Erlang is very simple language. The problem is that this language requires a little bit different approach to thinking, and this is the "hard part".

  • @unvergebeneid
    @unvergebeneid 4 ปีที่แล้ว +36

    This was brilliant! I had always wondered what made Erlang so special!

    • @jsonkody
      @jsonkody 3 หลายเดือนก่อน

      Yes, it's indeed very special and it's a shame that it does not have the attention it deserves. Now with Elixir it slowly changing.

  • @KentHambrock
    @KentHambrock 3 ปีที่แล้ว +11

    I've been learning Erlang over the last two weeks and I love it. It's so weird, but so damned fast to code in.

  • @lpil
    @lpil 4 ปีที่แล้ว +71

    • @LucienHughes
      @LucienHughes 4 ปีที่แล้ว +2

      He slightly reminds me of Jose Mourinho

    • @keedt
      @keedt 4 ปีที่แล้ว +3

      @@LucienHughes jose mourinho minus the ego

  • @ankk98
    @ankk98 3 ปีที่แล้ว +9

    Declarative programing
    Let the code fail (No guard clauss)
    Runs on virtual machine
    Seperate process for every task
    Fault tolerance
    Scalability
    Can run in a cluster of machines and pass messages

  • @lifelover69
    @lifelover69 4 ปีที่แล้ว +9

    Awesome intro to erlang, I'm very motivated to learn more, thank you!

  • @hereallyfast
    @hereallyfast 2 ปีที่แล้ว +4

    I have a question. What are we doing? Why have I learned object oriented programming? This is awesome. This is next level

  • @amirhasanbasic2193
    @amirhasanbasic2193 4 ปีที่แล้ว +1

    You are hitting bang on with the last few videos, really interesting.

  • @jabuci
    @jabuci 2 ปีที่แล้ว +1

    Every word of his was golden. I enjoyed listening to him. Thanks!

  • @borntolose_livetowin
    @borntolose_livetowin 3 ปีที่แล้ว +2

    Erlang got my curiosity because it reminds of a city called Erlangen, but after watching this video - Erlang has my attention.

  • @rembautimes8808
    @rembautimes8808 2 หลายเดือนก่อน

    This was an amazing talk. Thanks - mind opener on different programming paradigm

  • @mikopiko
    @mikopiko 4 ปีที่แล้ว +3

    The BEAM vm is really powerful, thank you Erlang!

  • @benouattara6249
    @benouattara6249 4 ปีที่แล้ว +4

    please ask this man to create a full course

  • @callumstewart5891
    @callumstewart5891 4 ปีที่แล้ว +10

    It's all coming back to me now! Flashbacks ftw!

    • @danceswithdirt7197
      @danceswithdirt7197 4 ปีที่แล้ว +3

      Yeah! I wrote a chat server/client in Erlang during my university days. I love Erlang.

    • @callumstewart5891
      @callumstewart5891 4 ปีที่แล้ว +1

      @@danceswithdirt7197 I did that too! Well, maybe not for a chatbot, but I did something with it. I prefer Haskell, personally though.

    • @AndersJackson
      @AndersJackson 4 ปีที่แล้ว +2

      Yes, we did a computation server, that was able to move around for updates etc. We did that in Uppsala university around 1995 (some thing, don't remember). It had computation server management in Erlang and solving the problem with Prolog. :-)

  • @NikolajLepka
    @NikolajLepka 4 ปีที่แล้ว +8

    erlang! one of my favourites :D
    good to see it get some attention

  • @QtmMtrlzr
    @QtmMtrlzr 4 ปีที่แล้ว +9

    Erlang sounds pretty interesting, thanks for this explanation

  • @zecekobold2140
    @zecekobold2140 4 ปีที่แล้ว

    This is the best lecture on apoptosis on youtube.

  • @caw25sha
    @caw25sha 4 ปีที่แล้ว +66

    Can we please have another video with source code for a simple working program, and see it in action? I'm really impressed and intrigued by Erlang and want to know more.

    • @unknownunknown9160
      @unknownunknown9160 4 ปีที่แล้ว +2

      caw25sha I’d suggest looking into Elixir

    • @johnjoyce
      @johnjoyce 4 ปีที่แล้ว

      More Erlang and some Elixir

    • @PaulaJBean
      @PaulaJBean 4 ปีที่แล้ว +1

      A video about Elixir, then?

    • @ryan.winchester
      @ryan.winchester 4 ปีที่แล้ว +1

      Look up on TH-cam: Erlang The Movie

    • @mrhivefive
      @mrhivefive 4 ปีที่แล้ว +2

      Search for this presentation on TH-cam.
      GOTO 2019 • The Soul of Erlang and Elixir • Saša Jurić

  • @davidmccrea1232
    @davidmccrea1232 3 ปีที่แล้ว +3

    What an elegant design for error handling

  • @billfrug
    @billfrug 2 ปีที่แล้ว +4

    Beautiful language in my opinion.

  • @typograf62
    @typograf62 4 ปีที่แล้ว +3

    An impressive explanation.

  • @JockeTF
    @JockeTF 4 ปีที่แล้ว +2

    Excellent explanation! Thank you!

  • @ristekostadinov2820
    @ristekostadinov2820 4 ปีที่แล้ว +22

    Joe Armstrong was legend, rest in peace

    • @mikew2229
      @mikew2229 4 ปีที่แล้ว

      Riste Kostadinov the death cause of Joe is so strange, someone could never got infected such disease and passed away that quick

  • @jaszynek7640
    @jaszynek7640 4 ปีที่แล้ว +2

    I`m C++ and Erlang dev, Erlang supports actor model which is imo safest and easiest to maintain and scale up solution in design of concurrent systems, unfortunately it is not fast enough so there is a need to implement actor model in C++, and what was elegant and clean in Erlang becomes nightmare in C++.

  • @qzbnyv
    @qzbnyv 4 ปีที่แล้ว +13

    I'd like to see a comparison of the concurrency in Erlang (in more details) with Haskell's model, where Haskell's threads spawned with forkIO are also described similarly as "lightweight" (...but the communication between them in Haskell is done through the MVar data type and/or STM's TVar type). STM (Software Transactional Memory) in Haskell would probably be a great video on its own. Maybe another one for Graham Hutton? :)

    • @lpil
      @lpil 4 ปีที่แล้ว +16

      They are similar in many ways but one key way in which they are different is the garbage collection. Haskell's GC time cost is linear with the amount of memory used by all threads and can have large pauses for global GC. Erlang's GC is performed on a per-thread basis and as a result there is never any global pause. Erlang programs tend to have a much better 99th percentile latency than those written in Haskell, Java, etc.

    • @lpil
      @lpil 4 ปีที่แล้ว +11

      Another key point is that pervasive use of timeouts and assertions means that deadlocks are much rarer and are something that can be recovered from, while in Haskell it would cause the whole program to crash. Erlang has much better runtime error handling properties, though less ability to prevent runtime errors than Haskell due to lack of a static type system.

  • @AtticusBleep
    @AtticusBleep 4 ปีที่แล้ว +40

    So what does his shirt say at the bottom?!

    • @keedt
      @keedt 4 ปีที่แล้ว +54

      let it crash

    • @arvind31459
      @arvind31459 4 ปีที่แล้ว +17

      Camera man is an intern

    •  4 ปีที่แล้ว +21

      Wash at 40C

  • @jsonkody
    @jsonkody 3 หลายเดือนก่อน

    By the way, it's funny that Elixir/Erlang are considered functional languages (which they indeed are), but by implementing the actor model with message passing, they actually adhere more closely to the original OOP concept as Alan Kay intended it than many 'modern' OOP languages like Java.

  • @jhbonarius
    @jhbonarius 4 ปีที่แล้ว +4

    I've been programming in hardware description languages like VHDL and Verilog for many many years now, and it sounds like Erlang is very similar in architecture.

    • @kreuner11
      @kreuner11 2 ปีที่แล้ว

      Maybe because it's functional, so you explain what the result should be rather than the steps to achieve it?

  • @GuitarWithBrett
    @GuitarWithBrett 11 หลายเดือนก่อน

    Good stuff , use elixir at my work and this is a great breakdown of Erlang

  • @StanSensei
    @StanSensei 3 ปีที่แล้ว +2

    This guy makes programming sound cool.

  • @elixiradolfont
    @elixiradolfont 6 หลายเดือนก่อน

    4:03 Great animation showing how do we execute a function that uses pattern matching

  • @vanaesthetics3336
    @vanaesthetics3336 2 ปีที่แล้ว

    Cool video! Thanks for sharing

  • @jms019
    @jms019 4 ปีที่แล้ว +2

    Maybe reference the original Erlang movie which demonstrates process failure and live module replacement quite well

  • @MrManafon
    @MrManafon 4 ปีที่แล้ว +9

    A language created for todays web.

  • @rasmichael
    @rasmichael 4 ปีที่แล้ว +7

    I'm getting a flash-back! Long live the AXE!

  • @noahwilliams8996
    @noahwilliams8996 4 ปีที่แล้ว +7

    This is really amazing. I want to write code in Erlang now.

    • @JSDudeca
      @JSDudeca 4 ปีที่แล้ว +5

      It's recommended for most to write using Elixir which is a child of Erlang. Elixir, which uses the rock solid Erlang VM, has much nicer syntax, great libraries and an awesome community.

    • @peterr6205
      @peterr6205 4 ปีที่แล้ว

      @@JSDudeca Elixir is not a "child Erlang". Using that phrase suggests that it's somehow less powerful or is a watered down version. To most people who are familiar with more modern languages, the Elixir syntax and tooling will seem much more familiar, but rest assured it is in no way a "child Erlang". It has everything you would get with Erlang, plus some extras.

    • @JSDudeca
      @JSDudeca 4 ปีที่แล้ว

      @@peterr6205 - Your point is well taken. In re-reading my comment it was definitely a typo. I had meant that "Elixir is a child of Erlang". Elixir is an awesome language and I look forward to using it in future projects. I cannot see myself ever writing Erlang as Elixir has it all.

    • @Gwaerondor
      @Gwaerondor 4 ปีที่แล้ว +4

      @@JSDudeca In what way is Elixir "recommended" over Erlang? It's the same thing with different syntax. Elixir doesn't do anything that Erlang can't. It's based on preference and neither one is "recommended" over the other. I'll pick Erlang any day of the week to avoid half of my lines consisting of the keyword bloat that is "do" and "end" but completely understand why people who have done Ruby might want to pick Elixir instead.

    • @JSDudeca
      @JSDudeca 4 ปีที่แล้ว +2

      @@Gwaerondor If working on small personal projects, it's really up to the person but in big teams
      However with Elixir it is a much easier language to get new team members, train up new talent, find support on issues etc. This is why I recommend Elixir to N00b's.

  • @MaxDiscere
    @MaxDiscere 4 ปีที่แล้ว +30

    It fascinates me everytime that old programming languages often seem more thoughtful constructed than lets say modern ones like javascript, even if they often had narrow usecases.

    • @dexter9313
      @dexter9313 4 ปีที่แล้ว +25

      Well Javascript is probably one of the worst languages ever created so yeah, not very representative of modern languages. There are way better ones out there. ;)

    • @addmoreice
      @addmoreice 4 ปีที่แล้ว +3

      @@dexter9313 *cough cough* MUMPS *cough cough* the worst programming language I was ever required to work with. . Javascript is brilliant in comparison.

    • @dexter9313
      @dexter9313 4 ปีที่แล้ว +8

      @@addmoreice Well that's why I said "one of the worst", because I'm sure there are some hidden gems here and there. ;) Should have said "worst popular language" maybe.

    • @shayneoneill1506
      @shayneoneill1506 4 ปีที่แล้ว +1

      @@addmoreice Bringing up Mumps is kind of cheating. it was always considered a dog ugly language with incomprehensible semantics.

    • @Blitterbug
      @Blitterbug 4 ปีที่แล้ว +3

      Yeah, I wouldn't call Javascript a language as much as it is scripted, bastardised C++.

  • @BenMursa
    @BenMursa 4 ปีที่แล้ว +1

    That factorial program is so simple but so cool too

    • @meowsqueak
      @meowsqueak 4 ปีที่แล้ว +1

      Indeed. Factorial programs are the “hello, world!” programs for functional programming languages.

  • @FeelsDonkMan
    @FeelsDonkMan 4 ปีที่แล้ว +2

    Great explanation thank you.

  • @ataksnajpera
    @ataksnajpera 4 ปีที่แล้ว +5

    This process isolation looks very similar to what chrome and firefox browsers are doing from some time. They also spawn multiple instances and then communicate via messages. Also when one card crashes it will not hang whole browser. Supervisor process will simply terminate crashed process.

    • @gang_albanii
      @gang_albanii 9 หลายเดือนก่อน

      yeah! but browsers do it for security primairly

  • @welltypedwitch
    @welltypedwitch 4 ปีที่แล้ว +9

    This is very interesting compared to Elm. Unlike Erlang, in Elm you have to handle every possible error case explicitly. I think I still prefer Elm, but this is still really interesting!

    • @florianthelliez7739
      @florianthelliez7739 4 ปีที่แล้ว +7

      Elm is more akin to Haskell, in the way that it uses a strong type system, whereas Erlang has dynamic typing. Some people are working on a strongly type language that runs on the Erlang VM (Gleam) but it is still a work in progress so far.

    • @AndersJackson
      @AndersJackson 4 ปีที่แล้ว +1

      @@florianthelliez7739 there was also work that did type system checks on the Erlang program when compiling. I never heard how it worked out though.

    • @florianthelliez7739
      @florianthelliez7739 4 ปีที่แล้ว +1

      @@AndersJackson that might have been referring to dialyser, you should get a look at it. It is a bit bothersome to set up and get working properly apparently though.

  • @timibolu
    @timibolu 2 ปีที่แล้ว

    I love Francesco Cesarini

  • @catcatcatcatcatcatcatcatcatca
    @catcatcatcatcatcatcatcatcatca ปีที่แล้ว

    I was blown away by the brilliance of Erlang when I heard Joe Armstrongs presentations about it.
    Before that, Casey Muratoris criticism of OOP made me overreact a bit: I became very sceptical of systems that advocated abstractions and focused on “maintainability”, because, very often, “maintainability” just meant arbitrary idea of simplicity and willing blindness towards the actual complexity of the system.
    But Erlang ACTUALLY addresses those issues by doing something radically different. And the approach of it shows perfectly what is wrong with OOP.
    If you are writing a program that will be one process and one binary, you are fundamentally unable to handle errors and achieve structures like erlang is. So why are we hellbend on writing “provably safe” and “modular” code based on “frameworks” - when none of those are true for anyone else than the single developer?
    The overall binary is not provably safe, nor is the source code as a whole is. Erlang as a system can be.
    The application is not modular, as long as it runs as a single process. Erlang is naturally capable of distributed computation.
    And the “framework” is just code in your binary you most likely didn’t bother reading (and which might be amount too big to physically read by single human, in a month). That’s not a true framework, because that’s not a true structure. Erlang, being distributed on multiple physical machines, multiple VMs and multiple processes is a true framework.
    In comparison, the “frameworks” modern developers use is just copy-pasting code we might or might not have read, composed of copy-pasted code we most definitely did not read.
    Now that consumer processors no longer see as rapid growth in processing power - as while definitely very possible, such devices would be impractical to cool down in consumer devices, I really hope there is some big shift in culture of software and OS development.

  • @RawPeds
    @RawPeds 4 ปีที่แล้ว +1

    Erlang looks cool!

  • @udaysom3244
    @udaysom3244 3 ปีที่แล้ว

    Hey, this guy was at NIIT conference:)

  • @erlanmejia2140
    @erlanmejia2140 2 ปีที่แล้ว

    Thank you very much.

  • @Shadow81989
    @Shadow81989 4 ปีที่แล้ว +9

    Some of it reminds me of objects in other languages - they don't share memory, communicate by sending messages, supervisor objects decide what to do in a crash scenario, ...
    Would definitely be interesting to learn more about it!

    • @MikkoAhlroth
      @MikkoAhlroth 4 ปีที่แล้ว +9

      In fact some people have said that Erlang is closer to the true idea of OOP than the usual OOP languages (C++, Java…). ;)

    • @hauleth
      @hauleth 4 ปีที่แล้ว +27

      Alan Kay (creator of the term Object Oriented Programming) once said that there are only 2 languages that implemented OOP as what he meant - Smalltalk and Erlang.

  • @K2gjbcfcvjbv
    @K2gjbcfcvjbv ปีที่แล้ว

    A Like and subscription because of the telephone in the background on the desk.

  • @davidgillies620
    @davidgillies620 4 ปีที่แล้ว +6

    Objective C is primarily a message-passing paradigm, and BeOS had it baked into the OS level. I think it started with Smalltalk. The idea of sharing memory by communicating rather than communicating by sharing memory is fundamental to Go (channels), as is very rapidly spawning lightweight processes (goroutines).

    • @ryan.winchester
      @ryan.winchester 4 ปีที่แล้ว +3

      Go has shared memory and channels are more like passing a baton than asynchronous communication between concurrent processes, no?

    • @AndersJackson
      @AndersJackson 3 ปีที่แล้ว +1

      Objects started with Simula, Object orientation started with Smalltalk. Compared to Smalltalk, C++, Java, C# etc are not object oriented languages.
      Smalltalk and Object orientation are about sending messages between objects, not calling methods. (That it is implemented as methods are another thing).

  • @seancharles1595
    @seancharles1595 4 ปีที่แล้ว +4

    I'm lucky enough to use Erlang and Elixir. Awesome!

  • @runefjord8446
    @runefjord8446 4 ปีที่แล้ว +1

    The last lair of the onion : an electromagnet that flips the switch and swings back to re-flip it before getting turned on again

  • @vinaysatish368
    @vinaysatish368 3 ปีที่แล้ว

    Awesome! Thank you

  • @hcblue
    @hcblue 4 ปีที่แล้ว +5

    Message passing, share-nothing design, and supervisors sound kinda cool, but what am I missing here? It would be lovely to get into the tradeoffs of Erlang's design (which, as with everything else in engineering, has a cost).

    • @PaulaJBean
      @PaulaJBean 4 ปีที่แล้ว +2

      It might be more difficult to find Erlang developers than JavaScript developers. They might cost more. Some people find Erlang's syntax ugly and/or unreadable. Luckily, there is Elixir.

    • @hauleth
      @hauleth 4 ปีที่แล้ว +4

      It needs some accustoming to be able to properly work with OTP (the supervisor thing in the video). Also as @Paula said, there are not that much developers, so it can be problem for some companies as well.

  • @Zolbat
    @Zolbat 4 ปีที่แล้ว +1

    Sounds pretty cool

  • @Furiends
    @Furiends 4 ปีที่แล้ว +1

    Its an important distinction that any concurrency must use message passing. This is excellent for information processing and servers but debilitating for something like operating system drivers.

    • @davidwuhrer6704
      @davidwuhrer6704 4 ปีที่แล้ว

      So drivers must not be concurrent.

    • @Furiends
      @Furiends 4 ปีที่แล้ว

      @@davidwuhrer6704 They have to be by definition unless you want your operating system to be like DOS.

    • @davidwuhrer6704
      @davidwuhrer6704 4 ปีที่แล้ว +1

      @@Furiends Then they must use some form of message passing.

    • @AndersJackson
      @AndersJackson 3 ปีที่แล้ว

      @@Furiends you can have the drivers to be non-concurrent, and let the OS handle the concurrency.
      And yes, most drivers are not concurrent.

  • @justahker3988
    @justahker3988 4 ปีที่แล้ว

    Any coverage on Brady's channels on the other Erlang? (Agner Krarup Erlang)

    • @anlonburke2885
      @anlonburke2885 4 ปีที่แล้ว +1

      Just FYI, this Erlang (the language) was actually named after the "other" Erlang :) That whole Erlang = "Ericsson language" theory is plain wrong.

  • @IshamMohamedIqbal
    @IshamMohamedIqbal 3 ปีที่แล้ว

    Is the "tread" he is mentioning @ 10:34, the OS thread?

  • @Ratebron
    @Ratebron 4 ปีที่แล้ว +52

    Erlangers rise up!

  • @manassricharanvarri
    @manassricharanvarri 4 ปีที่แล้ว

    You guys are best

  • @qm3ster
    @qm3ster 2 ปีที่แล้ว

    How is fallibility of network messaging handled though?
    Does it mean that sending a message to another process in the same supervisor tree is just as scary-looking as another node?

  • @formbi
    @formbi 4 ปีที่แล้ว +1

    in Scheme you can just do factorial like this:
    (define (factorial x) (apply * (iota x 1)))

  • @MrErtghj23
    @MrErtghj23 4 ปีที่แล้ว +4

    You should create some Erlang tutorials ❤️

    • @AndersJackson
      @AndersJackson 3 ปีที่แล้ว +2

      He has written at least one book about Erlang.

    • @dlabor1965
      @dlabor1965 2 ปีที่แล้ว

      Designing for Scalability with Erlang/OTP,
      Francesco Cesarini and Steve Vinoski

  • @hansisbrucker813
    @hansisbrucker813 4 ปีที่แล้ว +4

    I love Erlang.
    Btw, in the factorial example you could also use a pattern that matches one and you wouldn't have needed a when clause.

    • @PaulaJBean
      @PaulaJBean 4 ปีที่แล้ว +5

      But would that catch calling factorial() with a negative number?

    • @hansisbrucker813
      @hansisbrucker813 4 ปีที่แล้ว

      @@PaulaJBean Hmm, no

  • @thm6994
    @thm6994 2 ปีที่แล้ว +1

    Erlang is a computer language developed in Sweden by the Swedish telephone company Ericsson.

  • @swerasnym
    @swerasnym 4 ปีที่แล้ว +4

    Yey my current favorite language, did not expect to find it here!

  • @MaximumJoy
    @MaximumJoy 4 ปีที่แล้ว +16

    This guy has a way with words

  • @nnaaaaaa
    @nnaaaaaa 4 ปีที่แล้ว +78

    if erlang's syntax isn't your jam, elixir is actually really nice.

    • @tjpld
      @tjpld 4 ปีที่แล้ว +10

      jaff Elixir is the nicest language I have come across in the last 15 years.

    • @nnaaaaaa
      @nnaaaaaa 4 ปีที่แล้ว +2

      @@tjpld i wish i learned elixir far sooner than i did so i could've spent more time learning the right lessons.

    • @tjpld
      @tjpld 4 ปีที่แล้ว +11

      jaff Same. The thing that struck me the most was how little relevance control structures have in functional programming. The only thing your are going to use is case and cond, but even this is rare and you just pattern match most of the time. With any other language I end up with a mess of for loops, if, else and while statements.

    • @FeelsDonkMan
      @FeelsDonkMan 4 ปีที่แล้ว

      Very similar to Ruby for obvious reasons. Something I really want to learn as well.

    • @shayneoneill1506
      @shayneoneill1506 4 ปีที่แล้ว +5

      @@FeelsDonkMan The similarity to Ruby is fairly superficial. It does have some similaritys (do ... end blocks etc), but if you tried to use it in a Ruby style manner, I think you might end up making a big mess. Its not a procedural or OOP language.

  • @pspicer777
    @pspicer777 4 ปีที่แล้ว +3

    A small detail ... Should really be ... erlang/OTP. Nice videoo.

    • @peterr6205
      @peterr6205 4 ปีที่แล้ว

      They are used interchangeably, but Erlang/OTP is not somehow more correct than just saying Erlang.

  • @shalomhabibi9594
    @shalomhabibi9594 4 ปีที่แล้ว +15

    Team Erlang \o/
    What's your take on BEAM though

    • @peterr6205
      @peterr6205 4 ปีที่แล้ว +2

      I'm not sure I understand your question. BEAM is the runtime/VM that is used to run erlang(not directly, but after it's compiled to bytecode). Within the Erlang community, BEAM is the only major VM that is used, while there might be other implementations, I've never heard of anyone running anything except BEAM. So it would follow that anyone who is a fan/user of Erlang (or any other BEAM language, like Elixir), is a fan of the BEAM.

    • @shalomhabibi9594
      @shalomhabibi9594 4 ปีที่แล้ว

      @@peterr6205 BEAM is its own project though, I'd just like to hear their thoughts about it

    • @peterr6205
      @peterr6205 4 ปีที่แล้ว +2

      @@shalomhabibi9594 BEAM is not a separate project. BEAM is the reference implementation of Erlang. In a way, it IS Erlang. While you could argue Erlang is the syntax and rules of the language, in reality, Erlang is the compiler.VM that compiles and runs Erlang source code, and that currently is the BEAM.

    • @shalomhabibi9594
      @shalomhabibi9594 4 ปีที่แล้ว

      @@peterr6205 I give up

    • @peterr6205
      @peterr6205 4 ปีที่แล้ว +2

      @@shalomhabibi9594 I'm actually curious about what you'd like to know. My goal it not to be argumentative about your comment or request for info. For example, Java runs on the JVM, but there are also many other runtimes that people use, so understanding the differences, both technologically and politically (google vs oracle, etc.) makes a lot of sense, but with Erlang there's only one runtime, so therefore Erlang and the BEAM can be thought of as one thing. So anything you would learn about Erlang, would be applicable to BEAM. I'm curious what info you're looking for, or what facts you'd like about BEAM. I'm really not trying to be argumentative. I'd like to give you more info if I can. I've been working with Erlang and Elixir (both major BEAM languages) for over 3 years.

  • @jabuci
    @jabuci 2 ปีที่แล้ว

    Should I start learning Erlang or Elixir?

  • @ismaelgrahms
    @ismaelgrahms 5 หลายเดือนก่อน

    Gotta try Erlang

  • @dantenotavailable
    @dantenotavailable 4 ปีที่แล้ว +10

    ♥️ Erlang. RIP Joe Armstrong.

  • @itaco8066
    @itaco8066 3 ปีที่แล้ว

    Awesome thanks

  • @diegonayalazo
    @diegonayalazo 2 ปีที่แล้ว

    Thanks

  • @DaniErik
    @DaniErik 4 ปีที่แล้ว +3

    Hello Joe!

  • @alexandterfst6532
    @alexandterfst6532 4 ปีที่แล้ว +5

    Why is there no subtitles on this video ?

    • @sevcandincel
      @sevcandincel 4 ปีที่แล้ว +1

      It is sad.

    • @KingJellyfishII
      @KingJellyfishII 4 ปีที่แล้ว

      I'm kinda annoyed too

    • @caw25sha
      @caw25sha 4 ปีที่แล้ว +2

      This is currently a very new video and it sometimes takes a while for the subtitles to be generated. Try again tomorrow.

    • @KingJellyfishII
      @KingJellyfishII 4 ปีที่แล้ว

      @@caw25sha ah makes sense. Will do

    • @cesteres
      @cesteres 4 ปีที่แล้ว +2

      Subtitles in Erlang plz

  • @JerkerMontelius
    @JerkerMontelius 4 ปีที่แล้ว +1

    Hej Frasse.kul att se dig,

  • @oliverm.batista5445
    @oliverm.batista5445 4 ปีที่แล้ว +5

    OMG can we like this video twice?!

  • @striker865
    @striker865 4 ปีที่แล้ว +1

    Erlang is super cool

  • @NotGarbageLoops
    @NotGarbageLoops 2 หลายเดือนก่อน

    The captions are obsessed with Fred.

  • @TheOfficialPolo
    @TheOfficialPolo 4 ปีที่แล้ว +9

    Erlang are like onions. Onions have layers. Erlang has layers, onions have layers! You get it, they both have layers

    • @caw25sha
      @caw25sha 4 ปีที่แล้ว +6

      But Erlang doesn't make you cry ☺

    • @josipcuric8767
      @josipcuric8767 4 ปีที่แล้ว +3

      @@caw25sha the syntax sure does

    • @ulilulable
      @ulilulable 4 ปีที่แล้ว +4

      @@josipcuric8767 Nah, the syntax is fine; It even uses semicolon correctly.

    • @dexter9313
      @dexter9313 4 ปีที่แล้ว +3

      Everyone seem to miss the Shrek reference, but I sure won't !

    • @TheOfficialPolo
      @TheOfficialPolo 4 ปีที่แล้ว +3

      @@dexter9313 not the hero we need, but the hero we deserve

  • @AndersJackson
    @AndersJackson 4 ปีที่แล้ว +1

    Hej Francesco! :-)

  • @boboxiaodd
    @boboxiaodd 4 ปีที่แล้ว +1

    I love erlang, I use cowboy,vernemq

  • @Mattwoods35
    @Mattwoods35 3 ปีที่แล้ว

    I live for this sh**

  • @masoomsanadi
    @masoomsanadi 3 ปีที่แล้ว +1

    Why isn't there a common xmpp for all the world communication?

  • @keyhanjannatkhah6729
    @keyhanjannatkhah6729 2 ปีที่แล้ว +1

    ERLANG is awesome, it is ugly duck in technology, i believe ERLANG is one of most beautiful system in computer world.

  • @cxzuk
    @cxzuk 4 ปีที่แล้ว +6

    RIP Joe Armstrong

  • @Pyrazahn
    @Pyrazahn 4 ปีที่แล้ว

    So if variables can't be modified and there is no shared memory, how would you program something like a counter?

    • @sverkeren
      @sverkeren 4 ปีที่แล้ว +3

      recursion

    • @AndersJackson
      @AndersJackson 3 ปีที่แล้ว

      When you do calculation, you store the new result in a new variable. And because you do all loops in recursion, you do get a new set of variables each call. :-)
      And actually, non mutable variables the default in ML languages likeHaskell and OCaml. Nothing strange there at all, actually.

  • @naheliegend5222
    @naheliegend5222 4 ปีที่แล้ว

    Well, I don't get everything what he said. Any recommendations to read something about Erlang?

    • @HarmonicaTool
      @HarmonicaTool 4 ปีที่แล้ว

      I think "Seven Languages in Seven Weeks" has a chapter on it. "Seven More Languages..." has a chapter on Elixir.

  • @MrStevetmq
    @MrStevetmq ปีที่แล้ว

    I love how he says "very little memory, a few K" LOL when I was his age we would have said "very little memory a byte or two" LOL