Re: ThreadPoolExecutor backport



Philipp wrote:
Q: Why does the boolean flag isPaused need not be volatile?
As I see it, it will be polled and set by different threads and
nothing guarantees a memory barrier.

Nothing but the 'pauseLock.lock()', that is.

Thanks for your non-answer. It made me look harder.

"non-answer"? It turned to to be exactly the answer, as your
description clearly shows.

Happy to help.

--
Lew


.