RFR: 8316156: (ch) Channels.newOutputStream(ch).write(bigByteArray) allocates a lot of direct memory

Brian Burkhalter bpb at openjdk.org
Thu Sep 14 03:16:23 UTC 2023


In `ChannelInputStream` and `ChannelOutputStream`, process small chunks of bytes in sequence to avoid running afoul of the `MaxDirectMemorySize`.

-------------

Commit messages:
 - 8316156: Channels.newOutputStream(ch).write(bigByteArray) allocates a lot of direct memory

Changes: https://git.openjdk.org/jdk/pull/15733/files
 Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=15733&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8316156
  Stats: 94 lines in 3 files changed: 88 ins; 0 del; 6 mod
  Patch: https://git.openjdk.org/jdk/pull/15733.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/15733/head:pull/15733

PR: https://git.openjdk.org/jdk/pull/15733


More information about the nio-dev mailing list