Datadog
Datadog output plugin for Fluentd
Overview
It mainly contains a proper JSON formatter and a socket handler that streams logs directly to Datadog - so no need to use a log shipper if you don’t want to. For details, see https://github.com/DataDog/fluent-plugin-datadog.
Example
spec:
datadog:
api_key:
value: '<YOUR_API_KEY>' # For referencing a secret, see https://kube-logging.dev/docs/configuration/plugins/outputs/secret/
dd_source: '<INTEGRATION_NAME>'
dd_tags: '<KEY1:VALUE1>,<KEY2:VALUE2>'
dd_sourcecategory: '<YOUR_SOURCE_CATEGORY>'
Configuration
Output Config
api_key (*secret.Secret, required)
This parameter is required in order to authenticate your fluent agent.
Default: nil
buffer (*Buffer, optional)
compression_level (string, optional)
Set the log compression level for HTTP (1 to 9, 9 being the best ratio)
Default: “6”
dd_hostname (string, optional)
Used by Datadog to identify the host submitting the logs.
Default: “hostname -f”
dd_source (string, optional)
This tells Datadog what integration it is
Default: nil
dd_sourcecategory (string, optional)
Multiple value attribute. Can be used to refine the source attribute
Default: nil
dd_tags (string, optional)
Custom tags with the following format “key1:value1, key2:value2”
Default: nil
host (string, optional)
Proxy endpoint when logs are not directly forwarded to Datadog
Default: “http-intake.logs.datadoghq.com”
include_tag_key (bool, optional)
Automatically include the Fluentd tag in the record.
Default: false
max_backoff (string, optional)
The maximum time waited between each retry in seconds
Default: “30”
max_retries (string, optional)
The number of retries before the output plugin stops. Set to -1 for unlimited retries
Default: “-1”
no_ssl_validation (bool, optional)
Disable SSL validation (useful for proxy forwarding)
Default: false
port (string, optional)
Proxy port when logs are not directly forwarded to Datadog and ssl is not used
Default: “80”
service (string, optional)
Used by Datadog to correlate between logs, traces and metrics.
Default: nil
slow_flush_log_threshold (string, optional)
The threshold for chunk flush performance check. Parameter type is float, not time, default: 20.0 (seconds) If chunk flush takes longer time than this threshold, fluentd logs warning message and increases metric fluentd_output_status_slow_flush_count.
ssl_port (string, optional)
Port used to send logs over a SSL encrypted connection to Datadog. If use_http is disabled, use 10516 for the US region and 443 for the EU region.
Default: “443”
tag_key (string, optional)
Where to store the Fluentd tag.
Default: “tag”
timestamp_key (string, optional)
Name of the attribute which will contain timestamp of the log event. If nil, timestamp attribute is not added.
Default: “@timestamp”
use_compression (bool, optional)
Enable log compression for HTTP
Default: true
use_http (bool, optional)
Enable HTTP forwarding. If you disable it, make sure to change the port to 10514 or ssl_port to 10516
Default: true
use_json (bool, optional)
Event format, if true, the event is sent in json format. Othwerwise, in plain text.
Default: true
use_ssl (bool, optional)
If true, the agent initializes a secure connection to Datadog. In clear TCP otherwise.
Default: true