-
Notifications
You must be signed in to change notification settings - Fork 707
Description
Problem Statement
It is not currently possible to configure resource detectors through otelconf. My specific use case would be adding container.id to the Collector's internal telemetry using the container detector.
Proposed Solution
Version 0.4.0 of opentelemetry-configuration was released a few weeks ago. Among many other things, it adds the ability to explicitly configure resource detectors. Implementing this version of the configuration in otelconf with the existing resource detectors from opentelemetry-go would solve my issue.
Alternatives
A more short-term solution would be to enable all available resource detectors by default, and filter the attributes they generate based on resource::detectors::attributes. According to this PR, this seems to have been the intent for version 0.3.0.
The lack of support can be worked around by using external detection code and injecting the resolved values into the configuration, but this may not always be easy or possible.