liveBook · Manning

Standard output

As explained in Logs and Telemetry

Standard output is the conventional output stream through which a process writes textual data for a receiving terminal, parent process, or redirected destination.

Standard output (stdout) is a process output stream commonly used for log events. A process writes a continuous, usually text-based event stream; local developers can view it in a terminal, while an execution environment can capture, combine, route, and archive it elsewhere. The application does not need to manage log files or know the final destination. section 3.3

Using stdout separates application behavior from log delivery, but raw print-style output has operational limits. Without a logging framework, changing detail levels, suppressing sensitive events, and maintaining consistent structure become harder. Configuration-driven logging frameworks can set thresholds and use appenders while leaving routing outside application logic. section 3.3.1

Common deployment patterns include:

  • Capture an application’s stdout through Fluent Bit’s stdin input and send the resulting events to an output destination. section 3.3.1
  • For short-lived Function-as-a-Service workloads, connect application stdout to Fluent Bit stdin, or use a logging-framework appender that communicates directly with Fluent Bit or Fluentd. section 3.5.3
  • In containers, let the runtime handle stdout and stderr, then use logging agents such as sidecars or node-level DaemonSets for cluster-level collection. section 4.7.1

Capture a redirected stdout stream

Configure Fluent Bit with the stdin input, assign a tag, and write matching events to captured.txt. Redirecting an application’s stdout into this process turns emitted log lines into Fluent Bit input for later routing or processing. section 3.3.1

Listing 3.2 Capturing stdout
[SERVICE]
  flush 1

[INPUT]
  name stdin        #1
  tag book_stdout       #2

[OUTPUT]
  match *
  name file
  path .
  file captured.txt

This configuration shows the stdin input tagged as book_stdout and a file output that writes captured events to captured.txt. section 3.3.1

Stdout is one input and output path within a wider observability flow. Fluent Bit can receive logs from files, HTTP, and forwarding as well as stdin, and can send events onward; metrics and traces are also supported. For networked forwarding, SSL/TLS can secure traffic and control certificate validation. section 3.9

How Logs and Telemetry covers it

How deep it goes
Explains routing responsibilities and operational trade-offs, while deferring detailed logging-framework treatment.
Examples
Demonstrates Fluent Bit stdin capture with a tag and file output, plus FaaS and Kubernetes deployment patterns.
What it assumes
Assumes familiarity with application logging and introduces stdout capture through Fluent Bit configuration.
What you can do after
Operate/configure stdout capture through Fluent Bit stdin and choose appenders or container logging agents when appropriate.
How it connects
Connects stdout with logging frameworks, Fluent Bit, Fluentd, stdin, containers, Kubernetes, and OpenTelemetry.

Also explained in

Compare how 6 books explain standard output →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Logs and Telemetry. The section links point to the parts of the book it draws on.