[crac] RFR: 8371462: [CRaC] Improve listening socket reopen through FD policies [v4]
Radim Vansa
rvansa at openjdk.org
Thu Nov 27 13:27:24 UTC 2025
> The current tests for listening socket reopen have two defects:
> * there is no thread calling accept() during the checkpoint, while normally servers would be waiting for new connections
> * non-blocking server sockets where `Selector.select()` is used for the blocking is not exercised at all
>
> As a result the scenario with Selector.select() fails to even close such server socket, due to FDs not in the `EpollSelectorImpl` not being processed after the selection keys are cancelled.
>
> Second problem is the reopen: servers can use long-lived key with `SelectionKey.OP_ACCEPT` interest. When the server socket is closed the key is cancelled; to handle this transparently we need to make the key valid again and register it with the channel and selector.
Radim Vansa has updated the pull request incrementally with one additional commit since the last revision:
Queue keys registration in ServerSocketChannelImpl
-------------
Changes:
- all: https://git.openjdk.org/crac/pull/275/files
- new: https://git.openjdk.org/crac/pull/275/files/e5a4e2f4..10138b43
Webrevs:
- full: https://webrevs.openjdk.org/?repo=crac&pr=275&range=03
- incr: https://webrevs.openjdk.org/?repo=crac&pr=275&range=02-03
Stats: 105 lines in 6 files changed: 53 ins; 49 del; 3 mod
Patch: https://git.openjdk.org/crac/pull/275.diff
Fetch: git fetch https://git.openjdk.org/crac.git pull/275/head:pull/275
PR: https://git.openjdk.org/crac/pull/275
More information about the crac-dev
mailing list