diff --git a/docs/collecting-container-logs.md b/docs/collecting-container-logs.md index df25915011..c6f1b51388 100644 --- a/docs/collecting-container-logs.md +++ b/docs/collecting-container-logs.md @@ -2,6 +2,27 @@ +- [Collecting Container Logs](#collecting-container-logs) + - [Configuration](#configuration) + - [Multiline log parsing](#multiline-log-parsing) + - [Conditional multiline log parsing](#conditional-multiline-log-parsing) + - [Log format](#log-format) + - [json log format](#json-log-format) + - [fields log format](#fields-log-format) + - [json_merge log format](#json_merge-log-format) + - [text log format](#text-log-format) + - [Problem](#problem) + - [Resolution](#resolution) + - [Setting source name and other built-in metadata](#setting-source-name-and-other-built-in-metadata) + - [Filtering](#filtering) + - [Modifying log records](#modifying-log-records) + - [Adding custom fields](#adding-custom-fields) + - [Persistence](#persistence) + - [Advanced Configuration](#advanced-configuration) + - [Direct configuration](#direct-configuration) + - [Disabling container logs](#disabling-container-logs) + - [Using OTLP Source](#using-otlp-source) + By default, log collection is enabled. This includes both container logs and systemd logs. This document covers container logs. @@ -138,6 +159,12 @@ We're going to demonstrate the differences between them on two example log lines { "log_property": "value", "text": "I am a json log" } ``` +#### `json` log format + +`json` log format is an alias for `fields` log format. + +See [`fields` log format](#fields-log-format) + #### `fields` log format Logs formatted as `fields` are wrapped in a JSON object with additional properties, with the log body residing under the `log` key.