Whatsapp System Design | System Design| HLD | High Level Design

แชร์
ฝัง
  • เผยแพร่เมื่อ 12 ก.ย. 2024

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

  • @thekingraghuraman
    @thekingraghuraman 6 วันที่ผ่านมา

    Perfect video, all functional requirements are covered.
    Please do add a new section on generic NFR, like how to improve latency and throughput and back of the envelope estimation as well

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

    Thanks for sharing, best video for this topic I've seen so far

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

      Thanks, hope this was helpful :) Do like and subscribe and share with your friends :) check out the other videos on high and low level designs as well

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

    Why are we going with Columnar cassandra database to store the messages? we're not doing any aggregation, and also don't we need our data to be consistent as well? would a document nosql database be better

    • @kushalNawalakha
      @kushalNawalakha 10 หลายเดือนก่อน

      Probably because we need to fetch All the messages from a single conversation. So reading that from columnar db might be fast.

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

    but in functional how are you writing consistency and availability together ?

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

    Bro from where u are getting so much knowledge . I watch ur 5 videos all are crystal clear

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

    Could you share any thoughts why do you prefer websocket to grps or graphQL? or just HTTP with long puuling? Supporting two different protocols looks like extra work on bothe client and BE sides

  • @CharityChemutai-bf5kc
    @CharityChemutai-bf5kc 6 หลายเดือนก่อน

    Nice video thanks sir✊✊✊

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

    Fantastic explanation !!

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

      Glad you liked, hope it was helpful :)

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

      @@TheTechGranth yes

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

      @@rajibguha6960 Glad to hear that!!!

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

    Thanks for the nice explanation, can you post video on youtube or any streaming site

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

      sure, I will be coming up with Netflix design soon

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

      Here you go, I hope this will be helpful: th-cam.com/video/NBO88PLGIis/w-d-xo.html

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

    Great video one doubt
    let's say when I go online I make websocket connect with chat servicer 1 and do the send thing etc... now I go offline so will that websocket connect b/w me and chat server gets removed and when I go online again so again a websocket connect will be made and this time this connection will be made to some other chat server right?

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

      Generally these connections work in pool, so when you go online a new socket connection will be made for you

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

    communication between server to server is also over web socket connection?

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

      Yes

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

      @@TheTechGranth thanks a lot for quick response 🙏

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

      @@rational5872 welcome. Do like and subscribe and share with others 🙂

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

    You are awesome ...nice way of explaining.well researched content

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

      Thank you. Glad you liked it. Do like and subscribe and share it with your friends :)

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

    One more thing if we don't use websocket protocol here then for each msg we will have to make the connection each time for new msg but with this websocket protocol it will make a connection and both client and server can send the messages.
    My friend was asked to make a bot chat system in which a real user will ask the question and the bot will answer it so the design you have explained can I refer the same design for this thing also?

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

      You can use this but In chat bot a simple http will work because there server is not sending a message rather response to your request. If you ask something to a chat bot, an api will look for that question in some knowledge base and return you a response to the question, this is the case with simple chat botS, which does not involve ML

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

    In the above scenario user2 web-socket connection resides in server S4, so when user1 send message it is received by server S1. How server S1 communicate with server S4 ?

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

      As part of your application, you will query redis to get the websocket connection for the receiver. From redis you know which machine holds the connection object, make a call to that machine to get the object. Btw your application shoould have an internal getter which will share the connection object stored in map.

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

      if a connection object could be shared among servers using Redis, why do we need to be linked to specific server then? can we simply put connection object in Redis cache itself and doesn't store any user-server mapping tables then?
      I don't think its possible to share connection using Redis, and there's should be simple API endpoint which allows server1 forward user's message to server2

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

    Is websocket over tcp?

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

    What is the purpose of second table (on right side of the screen) at around 28 mins

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

      That is the hashtable which contains userid and its websocket connection object

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

      But can’t we use the table on top left?

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

      @@ameynaik2743 that is to identify on which server a user connection os present, you can serialize and store this data in 1st table as well, I chose to store on local server in hashtable

  • @Miscellaneous-Things
    @Miscellaneous-Things 2 ปีที่แล้ว

    The system can't have both consistency and availability.