Distributed Systems 2.1: The two generals problem

Sdílet
Vložit
  • čas přidán 27. 07. 2024
  • Accompanying lecture notes: www.cl.cam.ac.uk/teaching/212...
    Full lecture series: • Distributed Systems le...
    This video is part of an 8-lecture series on distributed systems, given as part of the undergraduate computer science course at the University of Cambridge. It is preceded by an 8-lecture course on concurrent systems for which videos are not publicly available, but slides can be found on the course web page: www.cl.cam.ac.uk/teaching/212...

Komentáře • 22

  • @TheRohkan
    @TheRohkan Před 3 lety +80

    Wow, This series is a gift to the world

  • @maksadbek
    @maksadbek Před 3 lety +28

    Sir Martin Kleppmann, thank you for your brilliant lectures

  • @sgc11comps
    @sgc11comps Před 3 lety +22

    Reminds me of the quote from friends "They don't know that we know they know we know" 😂

  • @julissadc6303
    @julissadc6303 Před rokem

    Thanks for putting the entire series on youtube

  • @Picklerick8859
    @Picklerick8859 Před rokem

    Thank you for the lectures!! You explain the complex problems in such clear way

  • @fadygamilmahrousmasoud5863
    @fadygamilmahrousmasoud5863 Před 2 měsíci

    thank you, very informative and explantory

  • @PPopov-pi3mc
    @PPopov-pi3mc Před 3 lety

    Thank you very much for the lecture!

  • @MuhammadAli-01
    @MuhammadAli-01 Před rokem

    Thank you for sharing. Much Apprecitated!

  • @azixaka
    @azixaka Před 3 lety +1

    Thank you.

  • @yazidhanifi707
    @yazidhanifi707 Před 3 lety +3

    Poor customer is attacked by everyone

  • @anishsingla-pg2pd
    @anishsingla-pg2pd Před 2 měsíci

    so, there is no solution for this problem? we can only put checks in place to prevent it in a real life scenario ?

  • @aliberatcetin6765
    @aliberatcetin6765 Před 4 měsíci

    Although I have taken the DS course before, I still enjoy listening your valuable lectures again because your series are really intuitive. I think the difference between two generals and online shop is, there is no ACK for ACK in TCP which implicitly avoids loops like the way in two generals problem. The only thing that payments service care is whether the message eventually reaches the online shop.

  • @ori61511
    @ori61511 Před 2 lety

    i love you

  • @coding3438
    @coding3438 Před 2 lety +3

    So the way the online shop problem is different from the two generals problem is that , say if we were to to apply the online shop case to the two generals one, then what would happen is that is if general one attacks and general 2 doesn’t, the city doesn’t fight the general that’s attacking, because the other general isn’t by his side!
    In other words, either general is safe! Just like how the online shop is safe is they dispatch goods and card doesn’t get charged, because they can just charge later!
    However, in the original generals problem, there was no safety! Once a general attacks alone, there’s no coming back from the defeat!

    • @yuhangmiao2796
      @yuhangmiao2796 Před 2 lety

      Yeah, I think the two generals problem is unresolvable since it has a hidden requirement - two armies need to attack the city at the same day. Otherwise, army 1 can keep sending messenger to army 2 and only attack the city until getting the response that army 2 has attacked. The same to online shop. They can just dispatch goods until confirming payment has been set

    • @khaldrogo9451
      @khaldrogo9451 Před 2 lety

      Yes, the 2 generals is a bit exaggerated, because in real life, as Martin mentioned, there is always room for rollback. Hopefully, no lives are dependant on a distributed system (in some cases there are), but in a simpler case like the shopping website things can always be rolled back in case of failures.

  • @brucewayne2480
    @brucewayne2480 Před 2 lety

    Can a messenger be attacked and the message is changed ?

    • @kleppmann
      @kleppmann  Před 2 lety +6

      In some systems we assume that a message may be changed (perhaps by a malicious actor) as it travels through the network. See section 2.3 on system models.

    • @brucewayne2480
      @brucewayne2480 Před 2 lety

      @@kleppmann Thank you !

  • @alvinyang6068
    @alvinyang6068 Před 7 měsíci

    For people who are curious why algorithm like TCP 3 way handshake cannot solve the problem.
    ```
    The thought experiment involves considering how they might go about coming to a consensus. In its simplest form, one general is known to be the leader, decides on the time of the attack, and must communicate this time to the other general. The problem is to come up with algorithms that the generals can use, including sending messages and processing received messages, that can allow them to correctly conclude:
    Yes, we will both attack at the agreed-upon time.
    Allowing that it is quite simple for the generals to come to an agreement on the time to attack (i.e. one successful message with a successful acknowledgement), the subtlety of the Two Generals' Problem is in the impossibility of designing algorithms for the generals to use to safely agree to the above statement.
    ```
    Quote from wiki: en.wikipedia.org/wiki/Two_Generals%27_Problem