[9] RFR 8166253: (ch) FileLock object can get GC'd and result in unexpected release of file lock
Brian Burkhalter
brian.burkhalter at oracle.com
Wed Jan 31 16:01:17 UTC 2018
Hi Hamlin,
On Jan 30, 2018, at 9:32 PM, Hamlin Li <huaming.li at oracle.com> wrote:
>> http://cr.openjdk.java.net/~bpb/8166253/webrev.04/
> Second, although it will solve JDK-8166253, it will introduce a new issue by line 290("if (!ref.isValid()) {") in FileLockTable.java. I think all the refs in queue will satisfy the condition "ref.isValid()”,
I don’t think so because of lines 210 and 234 which are invoked during the explicit release of the lock or the channel close.
Thanks,
Brian
> so there will be no ref be removed by removeStaleEntries, it will increase queue infinitely, finally could get out of memory if long enough. And seems there is workaround for this new issue, because line 290 is the key point to fix the JDK-8166253.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/nio-dev/attachments/20180131/e968db7e/attachment.html>
More information about the nio-dev
mailing list