8203765: java/nio/channels/Selector/SelectAndClose: add some prints and @intermittent tag
Alan Bateman
Alan.Bateman at oracle.com
Thu May 24 16:14:28 UTC 2018
On 24/05/2018 15:27, Brian Burkhalter wrote:
>
> On May 24, 2018, at 12:34 AM, Alan Bateman <Alan.Bateman at oracle.com
> <mailto:Alan.Bateman at oracle.com>> wrote:
>
>> I assume the issue with the test is that closeThread closes the
>> Selector before selectThread calls select and this leads to the
>> ClosedSelectorException. The test gives selectThread two seconds to
>> block in select and it seems this is not enough on some (overloaded?)
>> test systems.
>
> I did not see that there was a ClosedSelectorException thrown.
>
>> One suggestion is […] Another suggestion is to get rid of closeThread.
>
> I was wondering whether it would be sufficient to put in the call
> selectThread.join() at the appropriate place.
>
Waiting for the selectThread to terminate would at least allow you to
capture the CloseSelectorException (assuming that is being thrown).
-Alan.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/nio-dev/attachments/20180524/1bab5d8a/attachment.html>
More information about the nio-dev
mailing list