Node.js is a serious thing now… (2023)

preview_player
Показать описание

Рекомендации по теме
Комментарии
Автор

i think there is some confusion as to the actual meaning of async. Async does not really have anything to do with threads. They are closely related but fundamentally separate. You can have async execution within a single thread, sometimes this is even more performant than using a thread pool. Async execution just means that the event loop can be passed off to other tasks.

christopher
Автор

Ah yes, multithreaded mutable data. What could go wrong?

buildwithaustin
Автор

Glad this video popped up on my feed, love the way your videos are made! Subscribed :)

DucklengUgly
Автор

People often confuse concurrency with parallelism, concurrent tasks run at the same time, but only one is executed at a given time, parallel tasks are executed at the same time, thus requiring synchronization

Momo-vyxw
Автор

Ryan, this is very helpful, actually you helped me understand Go, and node more as a professional developer who mains Typescript, Thank you!

kzakaria
Автор

i hit the subscribe button HAAARD
im going to explore the rest of your videos and hope they are just as well done!
thank you for the information and high quality production!

killjaqular
Автор

A few of your videos have been dropped into my homepage, you look like have some big balls man. The videos you make are mostly things I already know but haven't used yet but it's like you're introducing them nicely.

musassh
Автор

Thanks for sharing this really useful way of using worker threads. I'll have to give this a try.

colbr
Автор

Very good video, straight to the point, no BS, thanks!

edouardcourty
Автор

Man, congrats! Awesome video quality and content.

fernandojsantos
Автор

It is also possible to use the cluster built-in module is well-suited for scaling network applications, the cluster module is more suitable for scaling network applications, while the worker_threads module is more suitable for parallelizing CPU-bound tasks within a single process.

ibrahimhalouane
Автор

The way you speak and explain things is perfect and pleasing to listen to. Cheers

CharlesMacKay
Автор

That was pretty cool. Thanks for the video!

oPatrickVico
Автор

Node isn't always single-threaded, as its core is written in C/C++ and certain modules will run in separate threads. But Node's single-threaded nature means we avoid having to deal with potentially difficult to debug problems related to memory sharing / data synchronization between threads.

I/O, network, and CRUD operations against a database are usually the bottlenecks, not long-running code blocking the main thread.

robkom
Автор

That is a very useful video. Thanks a lot!

djcaesar
Автор

Very glad I saw this video! Makes me excited to do some more NodeJS development

gerryramosftw
Автор

Came here from Beyond Fireship. Nice video! Subscribed!

netd
Автор

Hey, I had some experience with this feature while doing PWA application. And sadly I should say, that Workers aren't "magic stick", that can fix any performance issue by just wrapping a code into it. One big limitation is that data, transferred between worker and main thread should be serialized. Serialization can cost more than performance you potentially got by splitting algorithm into threads.

sawinjer
Автор

Glad you discovered it!

~3 years ago I failed a junior interview because the interviewer asked me "why javascript was single threaded".

I explained her I felt that the question was a "gotcha question" because the initial affirmation was false and depending on the enviroment you could make use of multiple processes or threads with workers or clusters to achieve multithreading.

She laughed at me and told me I was wrong because javascript used the event loop and couldn't run on multiple threads. I don't think she was an engineer but to this day I'm not sure and I think she was following a script, a bad one as you can see...

Anyways, thanks for the video! Keep pushing!

joaomendoncayt
Автор

wow. just impressive how direct and well executed this video is. And it takes time and work. and you make it looks like simple. Just top of the line Job. Congratulations. The sad part is that I can only give a like once.

sergio_saad
visit shbcf.ru