addResourceAttributes

fun <T : Any> addResourceAttributes(attributes: Map<AttributeKey<T>, T>)(source)

Adds resource attributes to the OpenTelemetry configuration. Resource attributes are key-value pairs that provide metadata describing the entity producing telemetry data.

Parameters

attributes

A map where the keys are of type AttributeKey and the values are of type T. These attributes will be added to the resource.

T

The type of the values in the attribute map, which must be non-null.