Skip to main content

spawn_stream_forwarder

Function spawn_stream_forwarder 

Source
pub fn spawn_stream_forwarder<S>(
    stream: S,
    module: String,
    instance_id: Uuid,
    cancel: CancellationToken,
    kind: StreamKind,
) -> JoinHandle<()>
where S: AsyncRead + Unpin + Send + 'static,
Expand description

Spawn a task that reads lines from stdout and forwards them to tracing.

The task will run until either:

  • The stream is closed (child process exits)
  • The cancellation token is triggered