Open
Description
The AWS Go SDK currently supports several resource detectors for third party computing environments. It would be useful if customers could enable select detectors in the agent's TracerProvider, via an environment variable, to automatically add environment-specific attributes to the telemetry.
PHP instrumentation has a similar mechanism, see here.
If this approach is accepted, I will contribute a feature to enable AWS resource detectors (EC2, ECS, etc.) using an environment variable like OTEL_GO_DETECTORS, and use a similar priority as that of PHP.