RFR 8072030 Race condition in ThenComposeExceptionTest.java
Chris Hegarty
chris.hegarty at oracle.com
Tue Feb 3 14:25:33 UTC 2015
On 2 Feb 2015, at 11:36, Paul Sandoz <paul.sandoz at oracle.com> wrote:
> ...
>> This was a nasty race. In fact there is no guarantee that the CF, that sets the AtomicReference would even complete, without join/get, right ?
>>
>
> I think the async completion of the thenComposed task will trigger (in the same thread) the completion of the dependent whenCompleted task, such that one could use a count down latch (which would be an odd thing to use).
Ah ok. I was thinking of the chain of CF’s as a stream, where you need some action to pull the result through. I think it depends on the sequence of async and same thread stages, maybe not, I’d need to look into the details a little more.
-Chris.
> Paul.
More information about the core-libs-dev
mailing list