RFR: 8330077: Allow max number of events to be buffered to be configurable to avoid OVERFLOW_EVENT [v8]
Brian Burkhalter
bpb at openjdk.org
Thu Apr 18 17:26:58 UTC 2024
On Thu, 18 Apr 2024 07:20:27 GMT, Fabian Meumertzheim <duke at openjdk.org> wrote:
>> The limit on the number of events buffered for a single `j.n.f.WatchKey` is now configurable via the `sun.nio.fs.maxWatchEvents`.
>
> Fabian Meumertzheim has updated the pull request incrementally with one additional commit since the last revision:
>
> Rephrase implNote
test/jdk/java/nio/file/WatchService/LotsOfEntries.java line 32:
> 30: * @run main/othervm -Djdk.nio.file.WatchService.maxEventsPerPoll=invalid LotsOfEntries 600 fail
> 31: * @run main/othervm -Djdk.nio.file.WatchService.maxEventsPerPoll=-5 LotsOfEntries 5 fail
> 32: * @run main/othervm -Djdk.nio.file.WatchService.maxEventsPerPoll=5 LotsOfEntries 5 pass
I ran 100 repeats of this test on each of four different platforms. 398 executions passed, but two failed, both in the sub-test at line 32. I do not know what happened in these two cases for the sub-tests at lines 33-35 as these were not run. The output was like:
jtreg_open_test_jdk_java_nio_file_WatchService_LotsOfEntries_java/tmp/name7869734652501521174/entry1]
at LotsOfEntries.testCreateLotsOfEntries(LotsOfEntries.java:84)
at LotsOfEntries.main(LotsOfEntries.java:96)
at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
at java.base/java.lang.reflect.Method.invoke(Method.java:580)
at com.sun.javatest.regtest.agent.MainWrapper$MainTask.run(MainWrapper.java:138)
at java.base/java.lang.Thread.run(Thread.java:1575)
JavaTest Message: Test threw exception: java.lang.RuntimeException: Expected events on: [multiple flle names omitted]
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/18739#discussion_r1571124810
More information about the nio-dev
mailing list