A typical JVM implementation of dynamically scoped variables tends to use ThreadLocal variables.
In code that uses Futures pervasively, a thread can be used my multiple Futures. In such a setting, is it safe to use ThreadLocal based implementations?
If not, how do I emulate a dynamically scoped variable that can work with Futures? (i.e. a sort of FutureLocal variable)