Documentation ¶
Index ¶
Constants ¶
View Source
const ( // AttributeDatadogHostname the datadog host name attribute AttributeDatadogHostname = "datadog.host.name" // AttributeK8sNodeName the datadog k8s node name attribute AttributeK8sNodeName = "k8s.node.name" )
Variables ¶
This section is empty.
Functions ¶
func ContainerTagFromAttributes ¶ added in v0.33.0
ContainerTagFromAttributes extracts the value of _dd.tags.container from the given set of attributes.
func HostnameFromAttributes ¶
func HostnameFromAttributes(attrs pdata.AttributeMap) (string, bool)
HostnameFromAttributes tries to get a valid hostname from attributes by checking, in order:
a custom Datadog hostname provided by the "datadog.host.name" attribute
the Kubernetes node name (and cluster name if available),
cloud provider specific hostname for AWS or GCP
the container ID,
the cloud provider host ID and
the host.name attribute.
It returns a boolean value indicated if any name was found
func TagsFromAttributes ¶
func TagsFromAttributes(attrs pdata.AttributeMap) []string
TagsFromAttributes converts a selected list of attributes to a tag list that can be added to metrics.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.