At 4:30, I thought that there was a single queue holding tasks. The executor choose a free thread to execute the next task in that single queue. In what executor, do we have a queue of tasks for each thread?
Thanks for the brilliant video, as always, clear and concise. I am still curious how does the async IO, CPU sharing look like. In the examples all the tasks were completed e2e. Is there a correct way of using IO, to make sure it's FJP compliant?
There is no special way of using IO required. If you use blocking IO from within an ForkJoinPool, the thread will be blocked until the IO call finishes. The ForkJoinPool might start up extra threads in that case, but I don't actually know.
@@JakobJenkov Thanks for the reply. I'll do some reasearch, as you point our yourself, there should be a way to get multiple tasks to share the same CPU.
Jakob you have destroyed the fear of multithreading in my mind, I hope this video and the channel gets the popularity it deserves ❤
Thank you very much !! :-)
Love your style of teaching, you break down a concept and make it easy to follow with your diagrams and then showing the code demos.
Thank you !! I am glad it is helpful to you !! 😊😊
Jakob, you are purely a Legend. thanks a lot for the great explanations.
You are welcome! ... and thank you for your kind words! :-)
I've watched all of your videos on Concurrency and Multithreading, and they were incredibly informative. Thank you!
Thank you very much !!
I am happy you found them useful ! 😊
you make Java so much more interest! thank you!
Thanks a lot for your kind words !! 😊 ... and you are welcome !! 😊
Thanks for this amazing playlist and clear explanations. Learned a lot from this!!!
You are very welcome! :-)
Bro, your tutorials are amazing..
Waiting for Structured Concurrency in java..
Thank you 😊😊 Structured concurrency is an interesting area !! ... let me see when I have time for it 😊
Lengend Jakob thanks for your explaination on java topics with deep insight
as always, you're the best.
thank you very much ^^
Thank you very much :-)
Excellent tutorial, thank you very much!
You are welcome ! ... and thank you for your kind feedback! :-)
At 4:30, I thought that there was a single queue holding tasks. The executor choose a free thread to execute the next task in that single queue. In what executor, do we have a queue of tasks for each thread?
Some ExecutorService implementations have a single queue holding tasks internally. But the ForkJoinPool uses multiple queues.
should I learn operating system before learning java thread ?
No, that should not be necessary :-)
if Java was the Kingdom Jakob would be the King
I am probably more of an ambassador ;-)
Thanks for the brilliant video, as always, clear and concise. I am still curious how does the async IO, CPU sharing look like. In the examples all the tasks were completed e2e. Is there a correct way of using IO, to make sure it's FJP compliant?
There is no special way of using IO required. If you use blocking IO from within an ForkJoinPool, the thread will be blocked until the IO call finishes. The ForkJoinPool might start up extra threads in that case, but I don't actually know.
@@JakobJenkov Thanks for the reply. I'll do some reasearch, as you point our yourself, there should be a way to get multiple tasks to share the same CPU.
Best videos I've seen. I'm wondering why so low views !?
Thank you !!
You will have to ask TH-cam about the views... who knows how the TH-cam algorithms actually work... 🤷♂️