Skip to content

Commit 73a0d09

Browse files
committed
Support resource detectors for service telemetry
Signed-off-by: Israel Blancas <[email protected]>
1 parent 8dd89ec commit 73a0d09

File tree

25 files changed

+1591
-41
lines changed

25 files changed

+1591
-41
lines changed
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
# Use this changelog template to create an entry for release notes.
2+
3+
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
4+
change_type: enhancement
5+
6+
# The name of the component, or a single word describing the area of concern, (e.g. receiver/otlp)
7+
component: all
8+
9+
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
10+
note: Add support for resource detectors in service telemetry configuration
11+
12+
# One or more tracking issues or pull requests related to the change
13+
issues: [14311, 10909]
14+
15+
# (Optional) One or more lines of additional information to render under the primary note.
16+
# These lines will be padded with 2 spaces and then inserted directly into the document.
17+
# Use pipe (|) for multiline entries.
18+
subtext: |
19+
Service telemetry now supports automatic resource attribute detection using OpenTelemetry SDK detectors.
20+
Configure detectors under `service.telemetry.detectors` to auto-detect environment variables, host information, and cloud metadata.
21+
To use `OTEL_RESOURCE_ATTRIBUTES` and `OTEL_SERVICE_NAME` environment variables, enable the `env` detector.
22+
Supported detectors: env, host, aws (ec2/ecs/eks/lambda), gcp, azure.
23+
24+
# Optional: The change log or logs in which this entry should be included.
25+
# e.g. '[user]' or '[user, api]'
26+
# Include 'user' if the change is relevant to end users.
27+
# Include 'api' if there is a change to a library API.
28+
# Default: '[user]'
29+
change_logs: []

cmd/mdatagen/go.mod

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ require (
3737

3838
require (
3939
github.com/cespare/xxhash/v2 v2.3.0 // indirect
40-
github.com/davecgh/go-spew v1.1.1 // indirect
40+
github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect
4141
github.com/go-logr/logr v1.4.3 // indirect
4242
github.com/go-logr/stdr v1.2.2 // indirect
4343
github.com/go-viper/mapstructure/v2 v2.4.0 // indirect
@@ -53,7 +53,7 @@ require (
5353
github.com/mitchellh/reflectwalk v1.0.2 // indirect
5454
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
5555
github.com/modern-go/reflect2 v1.0.3-0.20250322232337-35a7c28c31ee // indirect
56-
github.com/pmezard/go-difflib v1.0.0 // indirect
56+
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
5757
github.com/spf13/pflag v1.0.9 // indirect
5858
go.opentelemetry.io/auto/sdk v1.2.1 // indirect
5959
go.opentelemetry.io/collector/component/componentstatus v0.142.0 // indirect

cmd/mdatagen/go.sum

Lines changed: 4 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

cmd/otelcorecol/go.mod

Lines changed: 59 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,20 +34,55 @@ require (
3434
)
3535

3636
require (
37+
cloud.google.com/go/compute/metadata v0.9.0 // indirect
38+
github.com/GoogleCloudPlatform/opentelemetry-operations-go/detectors/gcp v1.30.0 // indirect
39+
github.com/aws/aws-sdk-go-v2 v1.40.1 // indirect
40+
github.com/aws/aws-sdk-go-v2/config v1.32.3 // indirect
41+
github.com/aws/aws-sdk-go-v2/credentials v1.19.3 // indirect
42+
github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.18.15 // indirect
43+
github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.15 // indirect
44+
github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.15 // indirect
45+
github.com/aws/aws-sdk-go-v2/internal/ini v1.8.4 // indirect
46+
github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.4 // indirect
47+
github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.13.15 // indirect
48+
github.com/aws/aws-sdk-go-v2/service/signin v1.0.3 // indirect
49+
github.com/aws/aws-sdk-go-v2/service/sso v1.30.6 // indirect
50+
github.com/aws/aws-sdk-go-v2/service/ssooidc v1.35.11 // indirect
51+
github.com/aws/aws-sdk-go-v2/service/sts v1.41.3 // indirect
52+
github.com/aws/smithy-go v1.24.0 // indirect
3753
github.com/beorn7/perks v1.0.1 // indirect
54+
github.com/brunoscheufler/aws-ecs-metadata-go v0.0.0-20221221133751-67e37ae746cd // indirect
3855
github.com/cenkalti/backoff/v5 v5.0.3 // indirect
3956
github.com/cespare/xxhash/v2 v2.3.0 // indirect
40-
github.com/davecgh/go-spew v1.1.1 // indirect
57+
github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect
4158
github.com/ebitengine/purego v0.9.1 // indirect
59+
github.com/emicklei/go-restful/v3 v3.13.0 // indirect
4260
github.com/felixge/httpsnoop v1.0.4 // indirect
4361
github.com/foxboron/go-tpm-keyfiles v0.0.0-20250903184740-5d135037bd4d // indirect
4462
github.com/fsnotify/fsnotify v1.9.0 // indirect
63+
github.com/fxamacker/cbor/v2 v2.9.0 // indirect
4564
github.com/go-logr/logr v1.4.3 // indirect
4665
github.com/go-logr/stdr v1.2.2 // indirect
4766
github.com/go-ole/go-ole v1.2.6 // indirect
67+
github.com/go-openapi/jsonpointer v0.22.3 // indirect
68+
github.com/go-openapi/jsonreference v0.21.3 // indirect
69+
github.com/go-openapi/swag v0.25.4 // indirect
70+
github.com/go-openapi/swag/cmdutils v0.25.4 // indirect
71+
github.com/go-openapi/swag/conv v0.25.4 // indirect
72+
github.com/go-openapi/swag/fileutils v0.25.4 // indirect
73+
github.com/go-openapi/swag/jsonname v0.25.4 // indirect
74+
github.com/go-openapi/swag/jsonutils v0.25.4 // indirect
75+
github.com/go-openapi/swag/loading v0.25.4 // indirect
76+
github.com/go-openapi/swag/mangling v0.25.4 // indirect
77+
github.com/go-openapi/swag/netutils v0.25.4 // indirect
78+
github.com/go-openapi/swag/stringutils v0.25.4 // indirect
79+
github.com/go-openapi/swag/typeutils v0.25.4 // indirect
80+
github.com/go-openapi/swag/yamlutils v0.25.4 // indirect
4881
github.com/go-viper/mapstructure/v2 v2.4.0 // indirect
4982
github.com/gobwas/glob v0.2.3 // indirect
83+
github.com/gogo/protobuf v1.3.2 // indirect
5084
github.com/golang/snappy v1.0.0 // indirect
85+
github.com/google/gnostic-models v0.7.1 // indirect
5186
github.com/google/go-tpm v0.9.7 // indirect
5287
github.com/google/uuid v1.6.0 // indirect
5388
github.com/grafana/regexp v0.0.0-20240518133315-a468a5bfb3bc // indirect
@@ -67,7 +102,7 @@ require (
67102
github.com/mostynb/go-grpc-compression v1.2.3 // indirect
68103
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
69104
github.com/pierrec/lz4/v4 v4.1.22 // indirect
70-
github.com/pmezard/go-difflib v1.0.0 // indirect
105+
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
71106
github.com/power-devops/perfstat v0.0.0-20240221224432-82ca36839d55 // indirect
72107
github.com/prometheus/client_golang v1.23.2 // indirect
73108
github.com/prometheus/client_model v0.6.2 // indirect
@@ -81,6 +116,7 @@ require (
81116
github.com/stretchr/testify v1.11.1 // indirect
82117
github.com/tklauser/go-sysconf v0.3.16 // indirect
83118
github.com/tklauser/numcpus v0.11.0 // indirect
119+
github.com/x448/float16 v0.8.4 // indirect
84120
github.com/yusufpapurcu/wmi v1.2.4 // indirect
85121
go.opentelemetry.io/auto/sdk v1.2.1 // indirect
86122
go.opentelemetry.io/collector v0.142.0 // indirect
@@ -135,6 +171,12 @@ require (
135171
go.opentelemetry.io/collector/receiver/xreceiver v0.142.0 // indirect
136172
go.opentelemetry.io/collector/service/hostcapabilities v0.142.0 // indirect
137173
go.opentelemetry.io/contrib/bridges/otelzap v0.13.0 // indirect
174+
go.opentelemetry.io/contrib/detectors/aws/ec2/v2 v2.1.0 // indirect
175+
go.opentelemetry.io/contrib/detectors/aws/ecs v1.39.0 // indirect
176+
go.opentelemetry.io/contrib/detectors/aws/eks v1.39.0 // indirect
177+
go.opentelemetry.io/contrib/detectors/aws/lambda v0.64.0 // indirect
178+
go.opentelemetry.io/contrib/detectors/azure/azurevm v0.11.0 // indirect
179+
go.opentelemetry.io/contrib/detectors/gcp v1.39.0 // indirect
138180
go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.63.0 // indirect
139181
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.63.0 // indirect
140182
go.opentelemetry.io/contrib/otelconf v0.18.0 // indirect
@@ -166,13 +208,28 @@ require (
166208
golang.org/x/crypto v0.46.0 // indirect
167209
golang.org/x/exp v0.0.0-20240506185415-9bf2ced13842 // indirect
168210
golang.org/x/net v0.48.0 // indirect
211+
golang.org/x/oauth2 v0.34.0 // indirect
212+
golang.org/x/term v0.38.0 // indirect
169213
golang.org/x/text v0.32.0 // indirect
214+
golang.org/x/time v0.14.0 // indirect
170215
gonum.org/v1/gonum v0.16.0 // indirect
171216
google.golang.org/genproto/googleapis/api v0.0.0-20251022142026-3a174f9686a8 // indirect
172217
google.golang.org/genproto/googleapis/rpc v0.0.0-20251022142026-3a174f9686a8 // indirect
173218
google.golang.org/grpc v1.77.0 // indirect
174219
google.golang.org/protobuf v1.36.11 // indirect
220+
gopkg.in/evanphx/json-patch.v4 v4.13.0 // indirect
221+
gopkg.in/inf.v0 v0.9.1 // indirect
175222
gopkg.in/yaml.v3 v3.0.1 // indirect
223+
k8s.io/api v0.34.2 // indirect
224+
k8s.io/apimachinery v0.34.2 // indirect
225+
k8s.io/client-go v0.34.2 // indirect
226+
k8s.io/klog/v2 v2.130.1 // indirect
227+
k8s.io/kube-openapi v0.0.0-20251125145642-4e65d59e963e // indirect
228+
k8s.io/utils v0.0.0-20251002143259-bc988d571ff4 // indirect
229+
sigs.k8s.io/json v0.0.0-20250730193827-2d320260d730 // indirect
230+
sigs.k8s.io/randfill v1.0.0 // indirect
231+
sigs.k8s.io/structured-merge-diff/v6 v6.3.1 // indirect
232+
sigs.k8s.io/yaml v1.6.0 // indirect
176233
)
177234

178235
replace go.opentelemetry.io/collector => ../../

0 commit comments

Comments
 (0)