Metric to Log
"Metric to log" refers to the process of transforming structured metric data into log format. This conversion is typically done for various reasons, and it serves several purposes:
Interoperability: Some systems or tools may require log data for analysis, visualization, or reporting. Transforming metrics to log format ensures interoperability with systems that are more accustomed to working with log data.
Human Readability: Logs are often more human-readable and contain more contextual information compared to aggregated metrics. Transforming metrics to logs may be useful when detailed information about individual events or transactions is needed for manual inspection or troubleshooting.
Alerting and Notification: Some alerting and notification systems are designed to work with log entries. By converting metrics to logs, organizations can leverage existing alerting mechanisms that are log-centric.
Host_tag
Optional: Defines the name of the tag used for the source host.
Description: When provided, the value of this tag is mapped to the generated log event's host field, with the field key specified by the global host_key option.
Example: host_tag: "host_name"
metric_tag_values
Optional: Controls the encoding of metric tag values.
Description:
single: Only the last non-bare value of tags is displayed with the metric. Multiple values for a tag show only the most recent value, and null values are ignored.
full: Exposes all metric tags as separate assignments, including multiple values for each tag.
Enum options:
full: Exposes all tag values.
single: Exposes only the last value of the tag.
Example: metric_tag_values: "full"
