MENU

Fun & Interesting

Java Asynchronous Programming Full Tutorial with Loom and Structured Concurrency - JEP Café #13

Java 50,467 3 years ago
Video Not Working? Fix It Now

Watch a live tutorial on how you can build real applications on top of virtual threads using the Structured Concurrency API, available as an incubator API in the JDK 19. ⎯⎯⎯⎯⎯⎯ Chapters ⎯⎯⎯⎯⎯⎯ 0:00 Intro 1:42 Two things about Virtual Threads 2:55 Writing asynchronous code 4:14 Moving asynchronous code to Virtual Threads 5:22 Introducing Loom Scopes 6:35 Live demo: a first StructuredTaskScope 9:13 Differences between Scopes and Executors 11:02 Introducing the ShutdownOnSuccess Scope 11:49 Live demo: using ShutdownOnSuccess 16:40 Exception handling 17:06 Creating a custom Scope in action 25:45 Tips to write unit tests 26:34 Live demo: handling different object types 33:10 Live demo: adding a timeout on your Scope 34:35 Using ExtentLocal instead of ThreadLocal 35:24 Live demo: using ExtentLocal in a single thread 37:04 Live demo: using ExtentLocal with scopes 39:17 Scope wrap up 40:31 Final words and outro ⎯⎯⎯⎯⎯⎯ Resources ⎯⎯⎯⎯⎯⎯ ◦ JEP Café on Virtual Threads ➱ https://youtu.be/UVoGE0GZZPI ◦ Inside Java Newscast on Loom ➱ https://youtu.be/UG9nViGZCEw and https://youtu.be/KuHhUDhIFYs ◦ Dev.java ➱ https://dev.java/ ◦ JEP 425: Virtual Threads (Preview) ➱ https://openjdk.java.net/jeps/425 ◦ JEP 428: Structured Concurrency (Incubator) ➱ https://openjdk.java.net/jeps/428 ◦ JDK 18 ➱ https://openjdk.java.net/projects/jdk/18 ◦ JDK 19 ➱ https://openjdk.java.net/projects/jdk/19 ◦ OpenJDK ➱ https://openjdk.java.net/ ◦ Oracle Java ➱ https://www.oracle.com/java/ ◦ JavaOne ➱ https://oracle.com/javaone Tags: #Java #ConcurrentProgramming #Loom #Java19 #OpenJDK #JDK #JDK19 #VirtualThreads #ConcurrentProgramming #JEPCafe #InsideJava

Comment