pub struct CommunicationLimits {
pub stdout_bytes: usize,
pub stderr_bytes: usize,
pub timeout: Option<Duration>,
}Expand description
Captured-output bounds and an optional deadline for caller-owned communication.
Use with communicate_child or communicate_child_with_observer. An
existing OutputLimits converts to these limits with its finite deadline.
Capture and executable-admission APIs continue to require OutputLimits.
Fields§
§stdout_bytes: usizeMaximum retained stdout bytes; zero permits only empty stdout.
stderr_bytes: usizeMaximum retained stderr bytes; zero permits only empty stderr.
timeout: Option<Duration>Positive deadline measured from communication entry, or no elapsed-time limit.
None still enforces output bounds, polls cancellation and cleans up on
failure. It can wait indefinitely for child exit or pipe EOF, including
descendant-held pipes with SuccessfulExit::Retain. Choose cancellation
and successful-exit policy deliberately. Cleanup timing remains governed
by the child’s crate::child::CleanupPolicy.