WebSockets Crash Course - Handshake, Use-cases, Pros & Cons and more

  Рет қаралды 297,289

Hussein Nasser

Hussein Nasser

Күн бұрын

Пікірлер: 346
@hnasr
@hnasr 5 жыл бұрын
Guys Jump codes for your convenience, HTTP 2:00 WebSockets 5:40 WebSockets Handshake 8:00 WebSockets Usecases 11:20 WebSockets Example Code 14:30 WebSockets Pros and Cons 36:40 Do you have to use webSockets? 42:10 Stay awesome!
@josepetoshi8135
@josepetoshi8135 4 жыл бұрын
Greate course mate!
@thanasisathanasi4965
@thanasisathanasi4965 4 жыл бұрын
Man, every part of your video is really for us. Very well documented and comprehensive! The best I could find./
@TheDroiDGch
@TheDroiDGch 4 жыл бұрын
The best channel about computer science!! thank you so much for these wonderful and helpful videos!
@reinohaider4239
@reinohaider4239 4 жыл бұрын
I need your help.. I need project for MSc computer network guys can any one help me!
@computeering
@computeering 4 жыл бұрын
Can you please make a comprehensive video about keeping track of clients using Websockets?
@truphenalwanga9829
@truphenalwanga9829 5 жыл бұрын
I always like it when a channel has the perfect balance of comedy and education. Subscribed! Great stuff!
@hnasr
@hnasr 5 жыл бұрын
Truphena Lwanga thanks ! Yeah hard to keep the balance. Do tell me if it gets little much. Any feedback helps. Enjoy the content. Cheers
@langsonchibili1329
@langsonchibili1329 5 жыл бұрын
THE FIRST 5 MINUTES INTO YOUR VIDEO MADE ME UNDERSTAND OVER 3 YEARS WORTH OF INFORMATION, U ARE A BLESSING Hussein Nasser
@tdias25
@tdias25 5 жыл бұрын
I cant believe i found this channel, this kinda of content is gold, please keep it up, also gonna watch that one about nodejs and webservers
@hnasr
@hnasr 5 жыл бұрын
Thanks! Very happy your enjoying the content
@molangdogma796
@molangdogma796 5 жыл бұрын
I HAVE NEVER KNOWN A GUY AS INTELLIGENT AT EXPLAINING STUFF LIKE Hussein Nasser, MUCH THANKS TO YOU SIR.
@hnasr
@hnasr 5 жыл бұрын
Molang dogma Thank you for watching you humbled me ❤️
@GoldenBeholden
@GoldenBeholden 3 жыл бұрын
I love these very bare-bones tutorials; after all, once you understand the essence of an API, using it to build an application is just a matter of applying whatever programming experience you may already have.
@hnasr
@hnasr 3 жыл бұрын
👍👍
@MrDeeb00
@MrDeeb00 Жыл бұрын
The most passionate instructor I have ever seen. Thank you for this awesome video!
@parmvirsidhu7563
@parmvirsidhu7563 4 жыл бұрын
I loved the way you start with WHY? then reasoning, when to use and when not to use, very practical approach to all the concepts. That helps in real life implementation decisions of the technology. Many Thanks for wonderful videos!
@sailendrapavan3475
@sailendrapavan3475 Жыл бұрын
I think Its better to search any topic in this channel first rather than wasting time in searching docs !!! Thanks Hussein Nasser 🤟
@section9999
@section9999 4 жыл бұрын
Your accent if fine my dude. We can totally understand what you're saying perfectly. Case in point, I also speak Spanish but no way in hell can I explain backend engineering topics of this level of technical detail in Spanish (or English) as clearly as you can in English. What matters more is the quality of your content, and you sir have some A grade quality content! After watching this I would subscribe, but problem is, I'm already subscribed!
@hnasr
@hnasr 4 жыл бұрын
Thank you Norberto 😍😍
@a7mdbest15
@a7mdbest15 6 ай бұрын
Just create an account and subscribe again 😂
@hawkeyeyt
@hawkeyeyt 28 күн бұрын
Thank you, thank you, thank you you're far too kind! The only web-socket video I needed. Please keep making these videos, you're an amazing teacher. Love you 3000 Hussein.
@omarkhaled1220
@omarkhaled1220 17 күн бұрын
Two minutes into the video and I'm in love with this channel
@shahinbayat
@shahinbayat 4 жыл бұрын
That was an amazing video, I didn't imagine to understand websockets this much comprehensive and with so much fun! keep going mate 👍
@hnasr
@hnasr 4 жыл бұрын
Appreciate you Sir! Thanks 😊 glad you enjoyed the content!
@shahinbayat
@shahinbayat 4 жыл бұрын
@@hnasr I can't stop enjoying the content you have created with such a great energy and giving them for free! That's amazing! I am suggesting your channel to everyone who is interested to learn about network with a simple language! 🙏
@gnack420
@gnack420 4 жыл бұрын
I gotta say, I love the way you present. It's very casual while still including a lot of information. Great video!
@hnasr
@hnasr 4 жыл бұрын
Nick Coad thanks! Glad you enjoy the content 😊
@shubhamkala5514
@shubhamkala5514 5 жыл бұрын
for me it's really difficult to watch such a long videos but your way of explaining things is so good that no one can resist it.Do make a video on EventSource.
@hnasr
@hnasr 5 жыл бұрын
Thanks ! I really appreciate your feedback. It is hard to explain complex topic in short video that is why my lectures are long. i try to include time codes of table of contents.. EventSource is on the list! 👍 Thanks!
@metinagaoglu4332
@metinagaoglu4332 4 жыл бұрын
Simple and very understandable.Thank you from Turkey, Hussein. I'm gonna watch your all videos.
@hnasr
@hnasr 4 жыл бұрын
Thank you Metin!!
@naimurhasanrwd
@naimurhasanrwd 2 жыл бұрын
Clicked the video, and this guy started explaining with the topic right from 0.00000 seconds! No channel intro, no personal intro.
@marcosvalderrey5063
@marcosvalderrey5063 2 жыл бұрын
Not every day I find great content that is also as engaging and entertaining as yours. Amazing job, Hussein!
@gussipp3
@gussipp3 2 жыл бұрын
if my career somehow took off it would be mostly because of you man, keep up the great content
@tech3425
@tech3425 2 жыл бұрын
I love how you always show the tech in the browser(the webRTC video also comes to mind), making it seem so simple that you can type it out in the console. No need for so much tooling. This is literally the only channel I've seen that does it like this.
@hnasr
@hnasr 2 жыл бұрын
i find it easier for simple things plus everyone has a browser and can quickly do it. not to say editors are not useful of course.
@tech3425
@tech3425 2 жыл бұрын
@@hnasr knowingly or not, it greatly reduces the cognitive overhead for viewers when learning a new tech
@tech3425
@tech3425 2 жыл бұрын
I was on another channel watching some web sockets stuff. It's amazing how simple and easy you make stuff sound.
@marianbieda
@marianbieda Жыл бұрын
Dziękujemy.
@taulantus
@taulantus 5 жыл бұрын
i usually don't comment, but i have to give you the props for this amazing video. good job
@hnasr
@hnasr 5 жыл бұрын
Thanks for taking the time to comment! Appreciate it , glad I could help. have a beautiful day. 😊
@patrickconrad396
@patrickconrad396 4 жыл бұрын
Just saying you're accent is fantastic man. No need to ever apologize. Well on you. I'm sure that took a lot of time
@hnasr
@hnasr 4 жыл бұрын
Patrick Conrad thanks Patrick
@patrickconrad396
@patrickconrad396 4 жыл бұрын
@@hnasr no thank you man. Only came across your videos today. Started learning a few months back but I feel like I've gained a way more enlightened idea of node and the backend itself just by watching your videos! Wish I'd have found them sooner! Can you recommend a playlist or perhaps even create one (I know you're probably busy) that is a good order for newbies to follow? **NVM I found it Thanks again!!
@Akonitx
@Akonitx Жыл бұрын
Bro, your videos with so passion and emotions is really something unbelievable comparing to other plain content in inet. Thanks for your existing!
@paulstaley4245
@paulstaley4245 5 жыл бұрын
I'm 11 minutes into this video and I love how professional this video is. Well done with the structuring! I can't believe this only has 4k views.
@hnasr
@hnasr 5 жыл бұрын
Thanks Paul! I appreciate your comment glad the content is of high value to you. Let me know what software engineering content would you like me to make. Cheers
@Mfbzai
@Mfbzai 3 жыл бұрын
Apple need this guy, the speaking way is awesome.
@BizimanaIsingizweChristian
@BizimanaIsingizweChristian 7 ай бұрын
Very good tutorial. I've been learning web sockets for a while without understanding them well but this video came as a solution. Thanks very much
@mhh263
@mhh263 4 жыл бұрын
Everyone thiinks Client-Server model is dead, but hey Hussein comes to rescue. Great stuff man 👍
@shinypants2204
@shinypants2204 3 жыл бұрын
Thanks!
@pragmaticsoftwareengineer7965
@pragmaticsoftwareengineer7965 5 жыл бұрын
excellent stuff mate. so glad I stumbled upon your channel.
@Gringo0517
@Gringo0517 4 жыл бұрын
Love the conversational tone. Great video!
@tech3425
@tech3425 2 жыл бұрын
Dude your accent is perfect. Fuck everybody making fun of it. I literally enjoy the way you pronounce stuff differently
@thomastaylor1799
@thomastaylor1799 3 жыл бұрын
#1 Your a smart dude. #2 You are a great teacher. #3 Don't apologize for your accent, it is cool!
@youee1234
@youee1234 5 жыл бұрын
Everything you publish is so pro! thanks for making our lives easier to grasp!
@hnasr
@hnasr 5 жыл бұрын
Thanks 😊 enjoy the content and let me know what you want to see next! Cheers and love
@thanasisathanasi4965
@thanasisathanasi4965 4 жыл бұрын
This definitely gets a like and saved in my favorite videos. Best tutorial on the subject !!!!
@hnasr
@hnasr 4 жыл бұрын
Thanks!! Enjoy the content ☺️☺️
@voxhominem
@voxhominem 4 жыл бұрын
damn that was actually helpful. I swear I've read 4 tutorials before now that couldn't have been harder to understand if they'd tried. you earned yourself a new subscriber my dude
@hnasr
@hnasr 4 жыл бұрын
Thank you Vox for watching and I am glad I earned your trust. Hopefully I deliver the content you enjoy cheers! thanks ..
@akashmocha4846
@akashmocha4846 4 жыл бұрын
Never felt learning was this "ENTERTAINING" before. More power to you❤️
@hnasr
@hnasr 4 жыл бұрын
❤️❤️❤️
@connordelaney2536
@connordelaney2536 3 жыл бұрын
Thank you for taking the time to make this. :)
@sajithtm4864
@sajithtm4864 3 жыл бұрын
You're such an amazing guy who brings out toughest concepts too simple. Keep doing Bro..👌
@moneeshkumar1838
@moneeshkumar1838 Жыл бұрын
Great Explanation Subscribed Keep posting
@ashishmaikhuri3950
@ashishmaikhuri3950 3 жыл бұрын
Nice work Hussain. I am finally able to understand websocket
@hnasr
@hnasr 3 жыл бұрын
🙏
@sakuranooka
@sakuranooka 3 жыл бұрын
@26:58: when I hit enter, I get an error message: Content Security Policy: The page’s settings blocked the loading of a resource at wss://localhost:8082/ (“connect-src”). What's the problem, how can I solve it? [PS: port 8082 is correct, I chose a different one than in the video]
@kidjr.9520
@kidjr.9520 Жыл бұрын
Very clear and the illustrations made it easier to visualize! Very Efficient video on web sockets!
@stevemcguigan8359
@stevemcguigan8359 2 жыл бұрын
Been waiting for an ah-ha moment on this for a while and this was it. Subbed.
@paulzaslavskij5472
@paulzaslavskij5472 3 жыл бұрын
Отличное видео! Отправляю овацию (40,00 ₽). 👏
@hnasr
@hnasr 3 жыл бұрын
Thank you!
@seems-legit
@seems-legit 3 жыл бұрын
You beautiful man, All other tutorials ive found have tried to make websockets seem like this dark mystic old gods tech that you haver to handle handshakes manually and send control frames. you got a subscriber
@reemachourey9462
@reemachourey9462 4 жыл бұрын
Came here from your Spotify Podcast! Happy to find awesome content.
@hnasr
@hnasr 4 жыл бұрын
Thanks Reema!!! Welcome to the channel. Enjoy the content 😊😊
@shrestha0144
@shrestha0144 3 жыл бұрын
I just love your teaching style
@sumedh1771
@sumedh1771 3 жыл бұрын
This is so awesome
@sunnysingh9270
@sunnysingh9270 4 жыл бұрын
@hussein. Sir, at time 28:43 , when i am typing form debug console --- connection.send("Hello client !!! its me a server"). Its throwing an error in the debug console itself ----Uncaught ReferenceError: connection is not defined. Can u please help me on that.
@guilhermecortes202
@guilhermecortes202 3 жыл бұрын
Same here guys. After running the command: connection.send("Hello from server here!") got this error: Uncaught ReferenceError: connection is not defined
@lex-fridman
@lex-fridman 2 жыл бұрын
@@guilhermecortes202 connection is available inside the callback function passed to websocket.on; So you will be able to do connection.send only durring the moment when debugger pauses on the call of that anonymous function (put a breakpoint inside its body).
@annyni6640
@annyni6640 3 жыл бұрын
Love your videos! Have never found anyone else who can teach better
@zolika154
@zolika154 4 жыл бұрын
literally had me laughing out loud like 3 times
@ajayraja1998
@ajayraja1998 4 жыл бұрын
the only video which explains very well thanks a lot brother
@briandines
@briandines 2 жыл бұрын
Excellent tutorial. You're funny which made this a little bit easier.
@TheMathematicalMan
@TheMathematicalMan 3 жыл бұрын
Thanks for the step-by-step guide!
@raffayhussain6717
@raffayhussain6717 3 жыл бұрын
The great John Danaher says learning should be playful. When I see you, it reminds me of him.
@SachinKumar-js8yd
@SachinKumar-js8yd 4 жыл бұрын
Liked, subscribed. Your content is GOLD.
@webrevolution.
@webrevolution. 2 жыл бұрын
19:15 Right there man. Right there you got my subscription. LOL.
@massimoaristide8879
@massimoaristide8879 3 жыл бұрын
Really easy and entertaining introduction.
@chintukarthi1781
@chintukarthi1781 3 жыл бұрын
thank you so much for the explanation. Really appreciate all your effort in making this video.
@bardhan.abhirup
@bardhan.abhirup 4 жыл бұрын
Hey Hussein, thanks a ton for the videos. Just discovered them. The content seems great! I hope you don't mind me saying that you volume levels need adjusting. At times it sounds like you're whispering into the mic and it's not audible, other times it's super loud. If you could somehow normalize that, it'd be great. Thanks!
@hnasr
@hnasr 4 жыл бұрын
Thank you so much! I am working on my audio and making better I think it got better on my new videos.
@ishdx9374
@ishdx9374 5 жыл бұрын
Thanks for this video, I found it really easy interesting, since I'm working on a web game right now.
@hnasr
@hnasr 5 жыл бұрын
Amazing! Keep us up to date with the progress of your game. Cheers!
@iyxan23
@iyxan23 3 жыл бұрын
I just love this channel!
@dabbopabblo
@dabbopabblo 2 жыл бұрын
Everything I make is with websockets. Maybe that's for the better or maybe its for the worst. I just loooove the bidirectional communication soo much, it allows me to monitor absolutely every little thing about the clients connected to my website in real time and provide them with live updates for the pages they are on
@edwinroman30
@edwinroman30 2 жыл бұрын
New subscriber. Awesome content and great explanation. I'm speechless many thanks for all and the recommended sources.
@lonewolf2547
@lonewolf2547 3 жыл бұрын
A M A Z I N G.....!!!!! awesome explanation dude
@sohamnavadiya992
@sohamnavadiya992 3 жыл бұрын
Learn a lot from your videos. Thank you for sharing. I have one request please upload one video on long pooling.
@hnasr
@hnasr 3 жыл бұрын
I Made a video a while back Long Polling and how it differs from Push, Poll and SSE - The Backend Engineering Show kzbin.info/www/bejne/gGHSnKWXfquDgJI
@rodeschorpioen
@rodeschorpioen 4 жыл бұрын
Cool and comprehensive video. thx and keep up the good work!
@hnasr
@hnasr 4 жыл бұрын
Thank you Wouter! 🙏
@richardmaduka4747
@richardmaduka4747 4 жыл бұрын
I'm glad I found your channel, you are great at explaining concepts.
@hnasr
@hnasr 4 жыл бұрын
Thank you! I am glad too that the content is useful 🙏😊
@newtonsarr1234
@newtonsarr1234 4 жыл бұрын
Your tutorials are just amazing. I love it.
@coolvjh
@coolvjh 3 жыл бұрын
Love your content. Keep them coming!
@SohailKhan-cb9ls
@SohailKhan-cb9ls 3 жыл бұрын
Thank you brother, you just solved a system design problem for me. You have a great and unique teaching technique, don't change it. I would really appreciate if you also cover cloud system designs. Thanks again 👍
@hnasr
@hnasr 3 жыл бұрын
🙏🙏🙏
@jervex-e3514
@jervex-e3514 Жыл бұрын
such as a treasure thanks!!
@JoaoRodrigues-yw3bh
@JoaoRodrigues-yw3bh Жыл бұрын
Amazing and timeless!!
@ajayraja1998
@ajayraja1998 4 жыл бұрын
seriously great video commenting second time brother
@hnasr
@hnasr 4 жыл бұрын
Haha glad you are enjoying the content
@AhmedAli-go7wx
@AhmedAli-go7wx 3 жыл бұрын
thanks, Nasser for this great content ...
@KunjaBihariKrishna
@KunjaBihariKrishna Жыл бұрын
I ended up here because I'm trying to connect to a websocket, but I can't find the first messsage that is sent from the browser. When I check the dev panel, the list of messages starts with a received message from the host I'm trying to figure out what sid the browser is sending so that I can establish a connection via python
@kaloyangeorgiev6824
@kaloyangeorgiev6824 Жыл бұрын
Thank you very much, amazing explanation!
@shaukat9823
@shaukat9823 4 жыл бұрын
Amazing stuff Hussein , Thanks a ton
@hnasr
@hnasr 4 жыл бұрын
Thank you dear
@jeppechristensen5707
@jeppechristensen5707 3 жыл бұрын
Thanks alot. You made me reconsider the EventSource API 🙂
@singaravelann3671
@singaravelann3671 4 жыл бұрын
Hi Hussain, I am really loving the way you deliver the content, can you please make a video to do the load balancer for websocket and how can we scale it horizontally.
@singaravelann3671
@singaravelann3671 4 жыл бұрын
I know we can do this by having the pub/sub model in the Backend, If you can make little crash course on this we will have clear idea.
@hnasr
@hnasr 4 жыл бұрын
Thanks ! I do explain how to secure web socket and load balance it through a reverse proxy here Secure WebSockets Explained by Example (with HAProxy) kzbin.info/www/bejne/iJeZcpmepq9-rsk
@singaravelann3671
@singaravelann3671 4 жыл бұрын
@@hnasr thanks hussian that's wonderful.
@azazel-oss
@azazel-oss 2 жыл бұрын
Love your content man, so full of information everytime I re-watch any of your long videos I always learn something new. Appreciate your work
@HosseinOjvar
@HosseinOjvar 4 жыл бұрын
I Like your narration Hussein, Continue boy ;)
@hnasr
@hnasr 4 жыл бұрын
Will do 😍
@KazLA
@KazLA 4 жыл бұрын
Wow you’re awesome - fun to follow
@hnasr
@hnasr 4 жыл бұрын
Wow, thank you appreciate it
@taihatranduc8613
@taihatranduc8613 4 жыл бұрын
you're so funny in the middle of the boring, cold, unemotional, coding world
@rshaikh05
@rshaikh05 3 жыл бұрын
jazakAllahu khair. keep up the good work.
@kjahirhussain
@kjahirhussain 3 жыл бұрын
Love the explanation!
@alitariq7726
@alitariq7726 Жыл бұрын
Love your work. 👍👍👍
@okage_
@okage_ Жыл бұрын
pretty good video, i learnt alot! thank you
@sourabhkumar6194
@sourabhkumar6194 2 жыл бұрын
Your tutorial really helped me, thanks
@seaofcuriosity
@seaofcuriosity 4 жыл бұрын
On sending data from server to client it says Uncaught Reference Error and it also not display message when new client is connected ....
@369-davian
@369-davian 9 ай бұрын
nice voice, my greetings from dominican republic
@CoentraDZ
@CoentraDZ 4 жыл бұрын
Your content is priceless ❤️
@hnasr
@hnasr 4 жыл бұрын
❤️❤️ thank you!!
@coutinhotiago
@coutinhotiago 4 жыл бұрын
Concerning the 2 TCP connections necessary to have redis pub/sub + req/rep: I believe that since redis RESP3 protocol (redis >=6) it possible to share both in the same TCP connection. BTW, it would be great to see you do a video on redis 6. Stay awesome 😎
@madanmohanpachouly6135
@madanmohanpachouly6135 2 жыл бұрын
Real cool explanation.
@jitpackjoyride
@jitpackjoyride 4 жыл бұрын
This is such great content, thank you.
@guilhermecortes202
@guilhermecortes202 3 жыл бұрын
Congrats Hussein it is a great tutorial and explanation about WebSockets. I like the way you start it simple. Unfortunately, the example didn't work for me. After following all the code when I was trying to run the command (on 28:40): connection.send("Hello from server here!") I got this error: Uncaught ReferenceError: connection is not defined (running the server on debug mode on VSCode). I tried to make some breakpoints like you did but still not working. Thanks for any help.
@lex-fridman
@lex-fridman 2 жыл бұрын
connection is available inside the callback function passed to websocket.on; So you will be able to do connection.send only durring the moment when debugger pauses on the call of that anonymous function (put a breakpoint inside its body).
@uchennanwanyanwu2777
@uchennanwanyanwu2777 5 жыл бұрын
7:14 ...it's the wild west. very funny explanation. cool
@coding3438
@coding3438 Жыл бұрын
Great video but can you please explain when you said at the start of the video, what does “opening a connection” mean? What exactly happens in the computer when you “open a connection”
gRPC Crash Course - Modes, Examples, Pros & Cons and more
1:19:38
Hussein Nasser
Рет қаралды 240 М.
Want to make a chat app? Get Real-time With WebSockets & Socket.io!
1:31:40
Good Morning Developers
Рет қаралды 23 М.
小丑教训坏蛋 #小丑 #天使 #shorts
00:49
好人小丑
Рет қаралды 54 МЛН
UFC 310 : Рахмонов VS Мачадо Гэрри
05:00
Setanta Sports UFC
Рет қаралды 1,2 МЛН
It works #beatbox #tiktok
00:34
BeatboxJCOP
Рет қаралды 41 МЛН
A Beginner's Guide to WebSockets
29:26
freeCodeCamp.org
Рет қаралды 333 М.
WebRTC Crash Course
1:10:06
Hussein Nasser
Рет қаралды 244 М.
How HTTP/2 Works, Performance, Pros & Cons and More
22:45
Hussein Nasser
Рет қаралды 110 М.
Server-Sent Events Crash Course
29:48
Hussein Nasser
Рет қаралды 100 М.
WebTransport is a Game Changer Protocol
14:23
Hussein Nasser
Рет қаралды 57 М.
HTTP Polling vs SSE vs WebSocket vs WebHooks
22:22
ByteVigor
Рет қаралды 16 М.
How to scale WebSockets to millions of connections
14:01
Ably Realtime
Рет қаралды 34 М.
SSL/TLS Termination, TLS Forward Proxy Pros and Cons
16:56
Hussein Nasser
Рет қаралды 33 М.
小丑教训坏蛋 #小丑 #天使 #shorts
00:49
好人小丑
Рет қаралды 54 МЛН