Тёмный

How To Code A Video Streaming Server in NodeJS 

AbdisalanCodes
Подписаться 5 тыс.
Просмотров 155 тыс.
50% 1

If you need help ask on discord! / discord
How to code a simple server that streams video instead of downloading the whole video.
Coding Begins: 1:53
Download Code: github.com/Abdisalan/blog-cod...

Наука

Опубликовано:

 

23 окт 2020

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 329   
@hnasr
@hnasr 3 года назад
Man this is pretty cool, thanks Abdi!! Keep it up Since the videoSize is unlikely to change, I would move the call to obtain the statsSync outside the /video endpoint.
@abdicodes
@abdicodes 3 года назад
I’m happy you liked it! I’m a fan of your channel 😄 And that makes a lot of sense, thanks for the feedback!
@Epistemer
@Epistemer 3 года назад
oh wow, I'm a big fan Hussein ❤
@dheerajsinghnagdali
@dheerajsinghnagdali 3 года назад
use stat method
@sanatgawade8045
@sanatgawade8045 2 года назад
But what if this method is fetching the video dynamically.?
@nirajmotiani
@nirajmotiani 2 месяца назад
this feels like a PR comment from senior engineer 😂
@stupidPeopleRBored
@stupidPeopleRBored 2 года назад
it is rare nowadays that yt feeds me content this valuable. well done, we need more creators like you...subbed!
@hbdarji
@hbdarji 2 года назад
Great explanation with the pros and cons, and especially the introduction. Keep going brother!
@gamingllama7464
@gamingllama7464 3 года назад
You know I have no idea who you are but just from that introduction I can already tell you'll have 100K subs within the next year
@hikari1690
@hikari1690 3 года назад
One month later and he's 10% of the way. He's ahead of schedule xD
@ShahriyarAlam1
@ShahriyarAlam1 2 года назад
Looks like this won't happen
@sheesh236
@sheesh236 2 года назад
@@ShahriyarAlam1 it will happen
@sheesh236
@sheesh236 2 года назад
@@ShahriyarAlam1 he just stopped uploading videos
@paulchaperon2207
@paulchaperon2207 2 года назад
Bruh
@chadzulu4328
@chadzulu4328 Год назад
Very clear and easy to understand explanation, thanks so much Abdi!
@Epistemer
@Epistemer 3 года назад
you explained everything so clearly, loved it
@franktfrisby
@franktfrisby 3 года назад
very cool and I like the way you walk through the video explaining all of the parts. Thanks
@shivangchaturvedi237
@shivangchaturvedi237 2 года назад
Man oh man!! Thank you! I will be waiting for more such content from you.
@ArisFilms
@ArisFilms Год назад
Extremely informative and straightforward. Thank you.
@midnightcigarettes8564
@midnightcigarettes8564 3 года назад
I'm trying to build an audio streaming server instead, and this is helping me get the blocks I need to piece things together. Thanks Abdi!
@karabomahlong9368
@karabomahlong9368 3 года назад
Im on a mission to build one as well but have no clue to go about it.. Im currently debating whether or not I should set up my own server or piggyback off of something like a Soundcloud. Would you kindly please share your journey so far?
@edwardmacnab354
@edwardmacnab354 2 года назад
I don't know why you don't do more videos like this. By just watching stuff like this people learn a lot and what might seem easy and obvious to you is pretty obscure to many of us. Thank you for this nice little presentation , It was very informative. But please, could we have more ?
@TroenderTass
@TroenderTass 2 года назад
That is because he really don't know what he's doing. he's just copy pasting a tutorial
@alexandrumarius5004
@alexandrumarius5004 3 года назад
Thank you man, very well explained, with all the details and very good English!
@alejandropoirier6493
@alejandropoirier6493 Год назад
Nice video, I'm a front end developer and I was contacted by a streaming company to have a chat, they offered my a position and I have to learn all this stuff as soon as posible :)
@arielspalter7425
@arielspalter7425 2 года назад
You've earned yourself another subscriber. Awesome tutorial!
@Pikachu-oo5ro
@Pikachu-oo5ro 3 года назад
Great Video! Hope to see more content! Young and Talented!
@aghiadalzein3069
@aghiadalzein3069 2 года назад
that was the most clear description,thanks
@dhyey2316
@dhyey2316 26 дней назад
This was amazing for clearing basics.
@markericfairweather9722
@markericfairweather9722 Год назад
This is Netflix's architecture. Love to see this Abdi!
@elad3958
@elad3958 Год назад
Thank you brother. I will try this out. I look forward to more tutorials
@thomasandon2539
@thomasandon2539 9 месяцев назад
Clear and straightforward! Thx.
@nadaz7333
@nadaz7333 3 года назад
This is really good! Keep going!
@joselito7776
@joselito7776 3 года назад
Thanks, dude, for showing me how to stream video. It also gave me the motivation to pay attention to http headers.
@abdicodes
@abdicodes 3 года назад
They are super important! Happy to have helped :)
@vaibhavpawar4535
@vaibhavpawar4535 3 года назад
Amazing 🔥 content ..... This channel is so underrated
@pavithranrocky316
@pavithranrocky316 3 года назад
Keep it up! Good Work Buddy...Very Helpful
@abdicodes
@abdicodes 3 года назад
Thanks! 😁
@paragbhide1695
@paragbhide1695 Год назад
awesome. have subscribed.. looking forward for more videos to learn!!!
@mendsalbert
@mendsalbert 3 года назад
a very cool tutorial.. Thanks mhan
@captainanonymous7090
@captainanonymous7090 3 года назад
Keep going bro. You’ve got good explanation
@abdicodes
@abdicodes 3 года назад
Thanks for the support!
@andrewndotela7407
@andrewndotela7407 3 года назад
Hey man, this is really helpful. Thanks
@dhanushkamadushan1989
@dhanushkamadushan1989 3 года назад
Really good explanation. keep it up.
@elieonokoko3782
@elieonokoko3782 2 года назад
This is great! Exactly what I was looking for. I am curious to know how you would implement view count. Thanks so much!
@CheezePie
@CheezePie 8 месяцев назад
You are the best❤ I'll try to implement this in Next.js
@ujwalc9226
@ujwalc9226 3 года назад
Awesome tutorial ,thank you soo much ♥️♥️♥️
@bevedel
@bevedel 3 года назад
Really helpful, Thank you so much. keep going please ...
@madbadseagulls1
@madbadseagulls1 2 года назад
Amazing tutorial, Thank you
@karnatakastatesyllabusexpl39
@karnatakastatesyllabusexpl39 3 года назад
It worked perfect Sir!
@bodolawale5448
@bodolawale5448 3 года назад
Loved it. Thanks.. I will build upon this
@karnatakastatesyllabusexpl39
@karnatakastatesyllabusexpl39 3 года назад
Thanks for the simple but useful video
@abdicodes
@abdicodes 3 года назад
Glad it was helpful!
@anikrish96
@anikrish96 3 года назад
got a lot of info here, thanks
@atalaysezen3391
@atalaysezen3391 Год назад
Thank you buddy, you should do more videos like this
@saramshshrestha7641
@saramshshrestha7641 Год назад
Love you man, you're great.
@sem_dev
@sem_dev 2 года назад
Love you for this video!!! Instant sub
@SemenAlexndrovich
@SemenAlexndrovich 2 года назад
great video! Thank you!
@juanoude
@juanoude 3 года назад
Nice video man. Thanks a lot.
@pushkarmahajan9294
@pushkarmahajan9294 Год назад
Awesome video!
@kuku5567
@kuku5567 3 года назад
you've earned a subscriber, thanks dude!
@abdicodes
@abdicodes 3 года назад
Awesome, thank you!
@nicetomeetugaming7024
@nicetomeetugaming7024 2 года назад
Thanks for this video!
@io-er1ex
@io-er1ex 3 года назад
Thanks this was very helpful. Keep it up
@abdicodes
@abdicodes 3 года назад
Glad it helped! 😁
@CodeProps
@CodeProps 2 года назад
That was really helpful, thanks
@konandev4278
@konandev4278 2 года назад
thats great bro, thank for video.
@ofiresaban4510
@ofiresaban4510 Год назад
Thanks! very useful
@learn_Japanese_with_sam
@learn_Japanese_with_sam 3 года назад
You are great man
@dannyquezada6986
@dannyquezada6986 3 года назад
Well explained!
@vishaljoshi6406
@vishaljoshi6406 3 года назад
really good! appreciate it
@brucebane7401
@brucebane7401 3 года назад
amazing bro!!!
@infinityApologeticsClips
@infinityApologeticsClips 2 года назад
This was amazing
@mohamedyoussef8835
@mohamedyoussef8835 2 года назад
Super Awesome explanation & topic ++++++++++++++++++++++ Thank You
@kj2w
@kj2w 10 месяцев назад
Great video! It helped me grasp an upcoming feature we are implementing. Question, what tests would be applicable to write for this?
@amoghgupta4466
@amoghgupta4466 3 года назад
awesome !! loved it!!
@bakamarimo7528
@bakamarimo7528 2 года назад
Great content man Subscribing hoping for more awesome content
@L1CBot
@L1CBot 11 месяцев назад
exactly what am I searching... 👍🏿👍🏿👍🏿
@coffeecuppepsi
@coffeecuppepsi 2 года назад
this is awesome thank you
@harshavardhannakkina1843
@harshavardhannakkina1843 3 года назад
great content thank you so much
@maskman4821
@maskman4821 3 года назад
Thank you for this tutorial, it is very cool and practical, we can let everyone access the server to see the video; I have a request, how do we send webcam video stream to server and let everyone views like youtube live stream ? It would be awesome if you can make such a tutorial and I think everyone wants to know how to achieve it !!!
@codeman8185
@codeman8185 Год назад
fantastic!
@irvagui
@irvagui 2 года назад
awesome, thank you!
@JenilCalcuttawala
@JenilCalcuttawala 3 года назад
Great tutorial Abdi. It would be helpful if you can also highlight how do we elevate this concept to streaming cloud storage contents i.e google cloud storage, aws s3.
@Linkplay9
@Linkplay9 Год назад
thanks for this! :)
@ayushmankumar7
@ayushmankumar7 3 года назад
Amazing !!!
@somyakantasahoo2335
@somyakantasahoo2335 3 года назад
Sir you make so good
@varunrajkumar2764
@varunrajkumar2764 3 года назад
Thanks, this really helped.
@abdicodes
@abdicodes 3 года назад
Glad it helped!
@RupamBumba
@RupamBumba 2 года назад
great video, make some more in details videos like that
@victorhernandezvillalobos7106
@victorhernandezvillalobos7106 3 года назад
Thank you so much, you are the best :'D
@lorenzopogliani120
@lorenzopogliani120 2 года назад
Thx, it was helpfull!!!
@tomjose4872
@tomjose4872 3 года назад
Good job mate
@karabomahlong9368
@karabomahlong9368 3 года назад
Hi there, thanks for the video! Im trying to build an audio streaming site but have no clue how to go about it.. Im currently debating whether or not I should set up my own server or piggyback off of something like a Soundcloud as an example. Would you kindly please share any tips for this kind of approach?
@voalcalisticTanmay
@voalcalisticTanmay 3 года назад
thanks a lot for the video ...
@mukiibipeter07
@mukiibipeter07 2 года назад
Hohooooo... this is it. Tanks bredda.
@1manbeats869
@1manbeats869 2 года назад
Very cool video, i like your code style and explanations. Just one thing, i believe this is not good to use statSync (or any sync IO function) inside a request handler, cause this would block the JS runtime event loop.
@abdishakur9
@abdishakur9 3 года назад
MashAllah keep up my dawg
@byronalas7848
@byronalas7848 2 года назад
You're so awesome!!! 😎😎😎😎
@OmAr-vv6fh
@OmAr-vv6fh 3 года назад
thank you bro . you rock
@codeflow5521
@codeflow5521 3 года назад
Zindabad Brother
@ominezx9
@ominezx9 3 года назад
its lit💥, thanks bruv.
@abdicodes
@abdicodes 3 года назад
Thank you! 🙏🏾
@penisatze
@penisatze 8 месяцев назад
thank you bro
@shubhamlahoti8152
@shubhamlahoti8152 2 года назад
Really appreciate your work ...Can you make more detail full stack live streaming project....
@jamespatterson1989
@jamespatterson1989 3 года назад
Hey I really did the clear explanation of both the overview and the line-by-line code. And such a simple code to illustrate the point. From the figure you have at 1:10, the two-way arrows got me wondering: how could we send recorded video from a client to the server in the same kind of bit-by-bit stream? I've build a client-side page that records video that I can then send to a server, but am looking to speed up the process and avoid saving anything client-side. Any ideas? Cheers!
@abdicodes
@abdicodes 3 года назад
I think that could work! You’ve got a good idea 😁
@valocraft1120
@valocraft1120 2 года назад
excellent
@pcmguru6011
@pcmguru6011 3 года назад
Can you please make a video which can demonstrate how to handle the pre-existing video data in frontend. As you suggested in the last part of the video. Please reply.
@dayronalfaro9461
@dayronalfaro9461 2 года назад
I think that pipe(res) maybe cause a memory leak if the peer close the connection, there is no code to close the stream if this happens, maybe you could use pipeline instead, this way it automatically close the stream. But good video
@niloymahmoodemon2409
@niloymahmoodemon2409 2 года назад
thanks man
@sonsimp3468
@sonsimp3468 Год назад
Hey I wanted ask but in containerized environments the video will not be on localhost, so what would be the ideal place to story them would s3 make sense ?.
@mahendranath2504
@mahendranath2504 3 года назад
This is cool man, as soon as I saw your post, I immediately jumped into implementing it, I feel so great about this after implementing it, thanks for sharing, can you do more tutorial about streaming and pipes, buffering, I see the network tab is having media ping with every time streaming is done, is that normal ? or can we hide that 206
@abdicodes
@abdicodes 3 года назад
There's no hiding
@sungjun94
@sungjun94 Месяц назад
Hi, can you deep dive into how pipe works and how req.headers.range is generated with new values?
@silugr
@silugr Год назад
Your video is really interesting . I have a challenge in this . I am downloading the file from a FTP location and the the received file is in the form of a stream . How to send that stream as chunks without storing the ftp received file in the local system ?
@semariaissac9119
@semariaissac9119 3 года назад
Thanks Abdi! Its a great info, do you have any idea how to stream kinesis video stream in node js within Amazon console?
@abdicodes
@abdicodes 3 года назад
I haven’t tried that but could be a cool video idea!
@amalbabu6607
@amalbabu6607 2 года назад
If I use fetch get request to get the video then where should I include ranges. When I include in header the subsequent requests shows 401 because of authentication middleware
@samplerun4686
@samplerun4686 3 года назад
i really like your concept, i have a question if you can answer. how do i switch between audio track if video file have multiple audio tracks? i couldnt find this solution where i can change my audio track in video controller. thank you
@farhanmirza52
@farhanmirza52 7 месяцев назад
thank you
@danielstella2425
@danielstella2425 Год назад
very useful, is it possibile to do with any mid-level language? such as Java, C#?
@thomasminoungou3779
@thomasminoungou3779 3 года назад
What a great tutorial!!! Just one question, who do I apply this but with a video store in the cloud? If you have any resource I will really appreciate it!
@abdicodes
@abdicodes 3 года назад
I don’t think this method can work with the cloud :/
Далее
How To Code A Video Stream using MongoDB
4:49
Просмотров 22 тыс.
3M❤️ #thankyou #shorts
00:16
Просмотров 7 млн
Live Streaming Architecture
14:47
Просмотров 127 тыс.
Node JS - HTTP Streaming
37:22
Просмотров 19 тыс.
Node.js Passport Login System Tutorial
36:28
Просмотров 1 млн