ProcessTransport.StdoutPump
Reads standard output without ever blocking on the pipe.
Source and package
- Qualified name
-
io.github .libtmux .transport .Process Transport .Stdout Pump - Package
- io.github.libtmux.transport
- Declared in
- ProcessTransport
- Distribution
- io.github.libtmux:libtmux
- Source
- libtmux/src/main/java/io/github/libtmux/transport/ProcessTransport.java
- class io.github.libtmux.transport.ProcessTransport.StdoutPump ( process: Process, limit: int, finished: Count
Down , failure: CompletableLatch Future <Throwable>, killedByClose: BooleanSupplier ) -
Description#
A read that blocks is a thread nothing can wake: tmux 3.0 and 3.1 daemons keep the client's standard output open after the client has exited, and closing the stream does not end a read already waiting in it. So this reads what is there and waits only while the process is alive. Once it has exited, everything it wrote is already in the pipe, so the pump reads while bytes are waiting and finishes at the first moment none are — a decision on the pipe's contents, not on a clock, which cannot drop bytes however long the pump was starved of a CPU.
- Parameters