On Tue, 4 Feb 2025 06:06:18 GMT, Alan Bateman <al...@openjdk.org> wrote:
> > > Do you expect there will be follow up work at some point for the commands > > > that upcall to Java and produce a byte[] to return to the tool? > > > > > > I don't see much need in the functionality now (streaming output is useful > > for commands which produce lengthy output or take long time to execute), > > but we can add it if desired - need to wrap native writer to OutputStream > > and use the stream by java handlers (instead of byte buffer) to write > > command output. > > Thread.dump_to_file is an example that needs this. There will be many more in > the future. So while not for this PR we should we thinking about a follow-up > to put in the infrastructure to support this. We have [JDK-8336723](https://bugs.openjdk.org/browse/JDK-8336723) to implement streaming output for commands implemented in java. This PR is lower level and provides functionality required for JDK-8336723 ------------- PR Comment: https://git.openjdk.org/jdk/pull/23405#issuecomment-2634917509