Spring into the Future: Embracing Virtual Threads with Java's Project Loom

  Рет қаралды 15,589

Dan Vega

Dan Vega

Күн бұрын

In this tutorial you will learn what Virtual Threads are in Java and how you can take advantage of them in your Spring Boot applications.
00:00 Introduction
00:08 Spring Developer Benefits
00:16 Virtual Threads Demo
00:26 JDK 21 & Spring Framework 6.1
00:38 Learning Virtual Threads
00:56 Thread Per Request Model
02:14 Scalability Solutions
03:35 Maximum Concurrent Threads
04:29 Asynchronous Programming
05:36 Introducing Virtual Threads
07:07 Spring Application Demo
10:22 Executor Modification
11:04 Virtual Thread Advantages
🔗Resources & Links mentioned in this video:
GitHub Repository: github.com/danvega/loom
Embracing Virtual Threads: spring.io/blog/2022/10/11/emb...
Web applications & Project Loom: spring.io/blog/2023/02/27/web...
👋🏻Connect with me:
Website: www.danvega.dev
Twitter: / therealdanvega
Github: github.com/danvega
LinkedIn: / danvega
Newsletter: www.danvega.dev/newsletter
SUBSCRIBE TO MY CHANNEL: bit.ly/2re4GH0 ❤️

Пікірлер: 29
@maneshipocrates2264
@maneshipocrates2264 Жыл бұрын
Thanks for the tutorial. This is good stuff from DV. Will like to use it in a multi module /microservices application
@albertodeluca4121
@albertodeluca4121 Жыл бұрын
What a nice and neat tutorial! Thanks
@badbaboye
@badbaboye 6 ай бұрын
Loving the content
@swe-step-by-step1017
@swe-step-by-step1017 Жыл бұрын
Thanks!
@markrensen9293
@markrensen9293 11 ай бұрын
Thanks Dan, I will be stealing these slides to learn my students about VT (most don't even know about threads, so it's a challenge)
@_leftii
@_leftii Жыл бұрын
How cool! Almost feels too easy! Love the content as always. Your style and delivery make concepts like this super easy to digest.
@bayonnesensei8281
@bayonnesensei8281 Жыл бұрын
Pretty nice, i know that it won't replace the webflux (reactive) and all (non-blocking and back-pressure ) but it is very nice improvement for Java itself.
Жыл бұрын
As always, nice content!!!. I wonder what we can do with those cheaps threads, maybe more connections to a database ? the concept of connection pool would change later?
@marouaniAymen
@marouaniAymen Жыл бұрын
Thanks for the explanation, I'd like to know what software or tool you did use to create the illustrations about threads. Thanks again.
@michelchaghoury9629
@michelchaghoury9629 Жыл бұрын
good video very informative, can you please make a video about Spring boot event sourcing / CQRS
@user-hz5hj5ro8i
@user-hz5hj5ro8i 11 ай бұрын
Could you tell me please what’s ide you are using and which theme? It looks great
@owlboom6458
@owlboom6458 6 ай бұрын
The idea of Java Virtual Threads was borrowed from Erlang Processes for BEAM virtual machine ))
@bulumkomadikane4543
@bulumkomadikane4543 3 ай бұрын
Kotlin coroutines
@Las0mbr4
@Las0mbr4 Жыл бұрын
Btw do you know if there's any database library that is loom ready ?
@mustafazuhair49
@mustafazuhair49 Жыл бұрын
Thanks that's great I'm very excited to use virtual thread but can we use virtual thread in production or we should wait until spring include this future
@mustafazuhair49
@mustafazuhair49 Жыл бұрын
@Spring Office Hours thank you
@user-wm2vu6gt3s
@user-wm2vu6gt3s 6 ай бұрын
Hallelujah...
@mohamadsharifi2353
@mohamadsharifi2353 Жыл бұрын
Is there any value to use virtual threads with webflux applications assuming there is a way to configure netty just like the way you configured tomcat?
@benaya6
@benaya6 9 ай бұрын
Consider a case when you use block to get the value of mono/flux, and do that in a virtual thrrad. You will get the value, but you won't really block anything
@sadiulhakim7814
@sadiulhakim7814 4 күн бұрын
Can i use Virtual Thread in every case? Is there any case where i cannot (should not) use Virtual Threads?
@rickhunter8216
@rickhunter8216 10 ай бұрын
NICE T-SHIRT.
@2wes
@2wes Жыл бұрын
where did you get this cool thsirt? =D
@mandarkulkarni7675
@mandarkulkarni7675 Жыл бұрын
Is it fair to say that if tasks being executed within the context of thread is primarily CPU intensive (or doesn't involve any blocking operations), then such task executions will NOT be benefited from virtual threads as eventually you will need an OS thread to execute the thread's core logic ?
@user-pi9cj2or5n
@user-pi9cj2or5n 8 ай бұрын
Yes, exactly. The benefit of a virtual thread is seen when you do io operations - db calls or other. If you have a huge cpu intensive calculation - the virtual thread has no benefit there, actually a bit of an overhead in that scenario
@jopadjr
@jopadjr Жыл бұрын
173rd...Thanks Dan
@lukasz8r
@lukasz8r Жыл бұрын
What is the IDE you are using here?
@DanVega
@DanVega Жыл бұрын
Intellij IDEA I documented my setup here if you're interested > kzbin.info/www/bejne/nWibmqZnZaudfJI
@scalacode
@scalacode 11 ай бұрын
Funny, Scala cats has such thing from many years back. Yet it is a preview in java.
@luisdanielmesa
@luisdanielmesa 4 ай бұрын
Forget Spring... plain vanilla Microprofile is more powerful. If you change to Helidon or Quarkus you'll have the cloud native experience, out of the box, that Spring doesn't give you, even jumping through hoops.
Китайка и Пчелка 4 серия😂😆
00:19
KITAYKA
Рет қаралды 1,1 МЛН
NO NO NO YES! (50 MLN SUBSCRIBERS CHALLENGE!) #shorts
00:26
PANDA BOI
Рет қаралды 102 МЛН
Java 21 new feature: Virtual Threads #RoadTo21
33:35
Java
Рет қаралды 55 М.
5 Common Mistakes Spring Developers Make
18:06
Dan Vega
Рет қаралды 14 М.
Virtual Threads in Java 21
17:22
Will Tollefson
Рет қаралды 2,4 М.
I Made 200 Python Projects...Here Are My 5 FAVORITES
11:23
Tech With Tim
Рет қаралды 128 М.
Java 21 Is Good?! | Prime Reacts
27:08
ThePrimeTime
Рет қаралды 211 М.
Xiaomi Note 13 Pro по безумной цене в России
0:43
Простые Технологии
Рет қаралды 2 МЛН
How To Unlock Your iphone With Your Voice
0:34
요루퐁 yorupong
Рет қаралды 17 МЛН
😱НОУТБУК СОСЕДКИ😱
0:30
OMG DEN
Рет қаралды 2,9 МЛН
Which Phone Unlock Code Will You Choose? 🤔️
0:14
Game9bit
Рет қаралды 13 МЛН
Топ-3 суперкрутых ПК из CompShop
1:00
CompShop Shorts
Рет қаралды 420 М.