filmov
tv
Java 20 - From ThreadLocal to ScopedValue with Loom Full Tutorial - JEP Café #16
![preview_player](https://i.ytimg.com/vi/fjvGzBFmyhM/maxresdefault.jpg)
Показать описание
ThreadLocal variables can help you share sensitive information among the different components of an application, without resorting to method calls. They have drawbacks that are now fixed with ScopedValue variables. Understand how ScopedValue are working and how you can use them as an incubator feature in JDK 20.
⎯⎯⎯⎯⎯⎯ Chapters ⎯⎯⎯⎯⎯⎯
0:00 Intro
1:09 Why have ThreadLocal variables been introduced?
2:44 How does ThreadLocal variables work?
4:57 ThreadLocal variables drawbacks: leaking and memory footprint
7:39 How Virtual Threads are changing the need for ThreadLocal
10:10 Introducing the new requirements for ScopedValue
11:02 Creating and using a ScopedValue
13:09 Reading a ScopeValue and dealing with errors
14:17 What is the scope of a ScopedValue?
16:59 Setting several ScopedValue for a task, rebinding a ScopedValue
17:55 Final words and outro
⎯⎯⎯⎯⎯⎯ Resources ⎯⎯⎯⎯⎯⎯
Tags: #Java #Java17 #Java20 #OpenJDK #JDK #JDK17 #Loom #VritualThreads #JEPCafe #insidejava
⎯⎯⎯⎯⎯⎯ Chapters ⎯⎯⎯⎯⎯⎯
0:00 Intro
1:09 Why have ThreadLocal variables been introduced?
2:44 How does ThreadLocal variables work?
4:57 ThreadLocal variables drawbacks: leaking and memory footprint
7:39 How Virtual Threads are changing the need for ThreadLocal
10:10 Introducing the new requirements for ScopedValue
11:02 Creating and using a ScopedValue
13:09 Reading a ScopeValue and dealing with errors
14:17 What is the scope of a ScopedValue?
16:59 Setting several ScopedValue for a task, rebinding a ScopedValue
17:55 Final words and outro
⎯⎯⎯⎯⎯⎯ Resources ⎯⎯⎯⎯⎯⎯
Tags: #Java #Java17 #Java20 #OpenJDK #JDK #JDK17 #Loom #VritualThreads #JEPCafe #insidejava
Комментарии