src/java.base/share/classes/java/lang/InheritableThreadLocal.java
Print this page
@@ -38,10 +38,15 @@
* <p>Inheritable thread-local variables are used in preference to
* ordinary thread-local variables when the per-thread-attribute being
* maintained in the variable (e.g., User ID, Transaction ID) must be
* automatically transmitted to any child threads that are created.
*
+ * <p>Note: During the creation of a new {@link
+ * Thread#Thread(ThreadGroup,Runnable,String,long,boolean) thread}, it is
+ * possible to <i>opt out</i> of receiving initial values for inheritable
+ * thread-local variables.
+ *
* @author Josh Bloch and Doug Lea
* @see ThreadLocal
* @since 1.2
*/