On Sat, 16 Apr 2022 11:06:21 GMT, Daniel Fuchs <[email protected]> wrote:
>> These changes make sure that pending requests are terminated if the selector >> manager thread exits due to exceptions. >> This includes: >> 1. completing CompletableFutures that were returned to the caller code >> 2. cancelling requests that are in flight >> 3. calling onError on BodySubscribers that may not have been completed >> Note that step 3 is necessary as certain CompletableFutures, such as those >> returned by `BodySubscribers.ofInputStream`, complete immediately, the >> operation being eventually completed when the last bite of the response is >> read. Completing a completable future that is already completed has no >> effect, this case is handled by completing the BodySubscriber too. > > Daniel Fuchs has updated the pull request incrementally with one additional > commit since the last revision: > > Fixed accepted exception logging in tests src/java.net.http/share/classes/jdk/internal/net/http/HttpClientImpl.java line 1056: > 1054: abortPendingRequests(owner, t); > 1055: } > 1056: Set<SelectionKey> keys = new HashSet<>(); I'm not quite understand, what for is this `keys` are here? Nothing happens with this collection after `addAll` call ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/7196#discussion_r1242094737
