opentelemetry-sdk 1.6.0 → 1.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e3ba5bcaae681a8f24969dd8aa7d886e0d1b57b3c26d46ef71bc2724bf5e7fe4
4
- data.tar.gz: 1d41a63a92487100a7f6a0e5fd74a18c92a7d9adf744ee561cc43e8def5c288b
3
+ metadata.gz: d021be149a4c1ae66baf57dae51ff1f45ea3e83f917e2b41d29f29ac8ca45c49
4
+ data.tar.gz: 8cc86b433df9cd5531ae6f24b2c9eea6ff55d74885d5acc6832b753421b1d5ec
5
5
  SHA512:
6
- metadata.gz: d6e3c2646902e1adb9efa33ab7d20b6d0a572c03e077a03b6cc13c1b94d95c2f41bcd1235b60f251384f9cd303fc49c4e3b88c2a6d6654e1de8b2356b3be6212
7
- data.tar.gz: 6729117a513daecc2d6f2e09de4601ca77777c51d0b110e3d4eea7a4365bcb1dffef201f529acb3479b20299e840154276fa2e50fd87871c575d7c859d36d848
6
+ metadata.gz: 3488104d3ad979539eb03af9880051f0ef6b44f286ce96ba4ac76ead66196134262ca16a2e9ee71cad8b28732ae7aafa23ca6a93fc51f96299d4219379adc282
7
+ data.tar.gz: cea1caca3a9ab2c7e130aff59f816336e62c127f730ab3f4a63c1d1b7fbbd9cf5c1ccc8517777887346709bfcb4843fae998a99790085951d372f7ed387e3f1c
data/CHANGELOG.md CHANGED
@@ -1,273 +1,293 @@
1
1
  # Release History: opentelemetry-sdk
2
2
 
3
+ ### v1.10.0 / 2025-10-14
4
+
5
+ * ADDED: Add span flags support for isRemote property
6
+
7
+ ### v1.9.0 / 2025-09-16
8
+
9
+ * ADDED: Add record_exception option for in_span
10
+
11
+ ### v1.8.1 / 2025-08-14
12
+
13
+ - FIXED: Remove patch constraint on Zipkin exporter
14
+ - DOCS: Fix Resource merge documentation
15
+
16
+ ### v1.8.0 / 2025-02-25
17
+
18
+ - ADDED: Support 3.1 Min Version
19
+
20
+ ### v1.7.0 / 2025-02-04
21
+
22
+ - ADDED: Add compatibility with env OTEL_SDK_DISABLED
23
+
3
24
  ### v1.6.0 / 2024-12-04
4
25
 
5
- * ADDED: Add hooks to configure logs
26
+ - ADDED: Add hooks to configure logs
6
27
 
7
28
  ### v1.5.0 / 2024-07-24
8
29
 
9
- * ADDED: Add add_link to span api/sdk
10
- * FIXED: Update `untraced` to suppress logging "Calling finish on an ended Span" warnings
30
+ - ADDED: Add add_link to span api/sdk
31
+ - FIXED: Update `untraced` to suppress logging "Calling finish on an ended Span" warnings
11
32
 
12
33
  ### v1.4.1 / 2024-03-21
13
34
 
14
- * FIXED: ForwardingLogger should forward block param.
35
+ - FIXED: ForwardingLogger should forward block param.
15
36
 
16
37
  ### v1.4.0 / 2024-01-25
17
38
 
18
- * ADDED: Add spans to Trace::ExportError
39
+ - ADDED: Add spans to Trace::ExportError
19
40
 
20
41
  ### v1.3.2 / 2024-01-23
21
42
 
22
- * FIXED: Reduce allocations on GraphQL hot paths
23
- * FIXED: Add context to metrics reporting of buffer-full events
43
+ - FIXED: Reduce allocations on GraphQL hot paths
44
+ - FIXED: Add context to metrics reporting of buffer-full events
24
45
 
25
46
  ### v1.3.1 / 2023-11-02
26
47
 
27
- * FIXED: Spec compliance for span attribute limit
28
- * FIXED: BatchSpanProcessor#force_flush: purge inherited spans even on shutdown
48
+ - FIXED: Spec compliance for span attribute limit
49
+ - FIXED: BatchSpanProcessor#force_flush: purge inherited spans even on shutdown
29
50
 
30
51
  ### v1.3.0 / 2023-06-08
31
52
 
32
- * BREAKING CHANGE: Remove support for EoL Ruby 2.7
53
+ - BREAKING CHANGE: Remove support for EoL Ruby 2.7
33
54
 
34
- * ADDED: Remove support for EoL Ruby 2.7
35
- * FIXED: SDK requires opentelemetry-common 0.19.7
55
+ - ADDED: Remove support for EoL Ruby 2.7
56
+ - FIXED: SDK requires opentelemetry-common 0.19.7
36
57
 
37
58
  ### v1.2.1 / 2023-05-30
38
59
 
39
- * FIXED: Untraced only works with parent-based sampler
40
- * DOCS: Improve formatting of usage examples in OpenTelemetry SDK rubydocs
60
+ - FIXED: Untraced only works with parent-based sampler
61
+ - DOCS: Improve formatting of usage examples in OpenTelemetry SDK rubydocs
41
62
 
42
63
  ### v1.2.0 / 2022-09-14
43
64
 
44
- * ADDED: Support OTEL_PROPAGATORS=none
45
- * ADDED: Support OTEL_ATTRIBUTE_{COUNT,VALUE_LENGTH}_LIMIT env vars
46
- * ADDED: Support InstrumentationScope, and update OTLP proto to 0.18.0
47
- * FIXED: SpanLimits setting event attributes length limit
65
+ - ADDED: Support OTEL_PROPAGATORS=none
66
+ - ADDED: Support OTEL*ATTRIBUTE*{COUNT,VALUE_LENGTH}\_LIMIT env vars
67
+ - ADDED: Support InstrumentationScope, and update OTLP proto to 0.18.0
68
+ - FIXED: SpanLimits setting event attributes length limit
48
69
 
49
70
  ### v1.1.0 / 2022-05-26
50
71
 
51
- * BREAKING CHANGE: This requires upgrading both the SDK and Instrumentation gem in tandem
52
-
72
+ - BREAKING CHANGE: This requires upgrading both the SDK and Instrumentation gem in tandem
53
73
 
54
74
  ### v1.0.3 / 2022-05-02
55
75
 
56
- * ADDED: Truncate the strings in an array attribute value if length_limit is configured
57
- * FIXED: Update attribute length limit env var name to match spec
58
- * FIXED: Warning about Struct initialization in Ruby 3.2+
59
- * FIXED: Warn on unsupported otlp transport protocols
60
- * FIXED: Only allow certain types of Numeric values as attribute values.
76
+ - ADDED: Truncate the strings in an array attribute value if length_limit is configured
77
+ - FIXED: Update attribute length limit env var name to match spec
78
+ - FIXED: Warning about Struct initialization in Ruby 3.2+
79
+ - FIXED: Warn on unsupported otlp transport protocols
80
+ - FIXED: Only allow certain types of Numeric values as attribute values.
61
81
 
62
82
  ### v1.0.2 / 2021-12-01
63
83
 
64
- * FIXED: Default span kind
65
- * FIXED: Use monotonic clock where possible
84
+ - FIXED: Default span kind
85
+ - FIXED: Use monotonic clock where possible
66
86
 
67
87
  ### v1.0.1 / 2021-10-29
68
88
 
69
- * FIXED: Add unexpected error handlign in BSP and OTLP exporter (#995)
89
+ - FIXED: Add unexpected error handlign in BSP and OTLP exporter (#995)
70
90
 
71
91
  ### v1.0.0 / 2021-09-29
72
92
 
73
- * (No significant changes)
93
+ - (No significant changes)
74
94
 
75
95
  ### v1.0.0.rc3 / 2021-08-12
76
96
 
77
- * BREAKING CHANGE: Remove optional parent_context from in_span
78
- * BREAKING CHANGE: Replace Time.now with Process.clock_gettime
79
- * BREAKING CHANGE: Refactor Baggage to remove Noop*
80
- * BREAKING CHANGE: Remove unnecessary readers from SDK Tracer
81
- * BREAKING CHANGE: Total order constraint on span.status=
82
- * BREAKING CHANGE: Use auto-generated resource constants in sdk and resource_detectors
83
- * BREAKING CHANGE: Span limits env vars
84
-
85
- * ADDED: Add Tracer.non_recording_span to API
86
- * ADDED: Add unnamed tracer warning message
87
- * ADDED: Allow disabling of install messages
88
- * ADDED: Make API's NoopTextMapPropagator private
89
- * ADDED: Use auto-generated resource constants in sdk and resource_detectors
90
- * ADDED: Allow selecting multiple exporter
91
- * ADDED: Add explicit BSP export error
92
- * FIXED: Remove optional parent_context from in_span
93
- * FIXED: Replace Time.now with Process.clock_gettime
94
- * FIXED: Rename cloud.zone to cloud.availability_zone
95
- * FIXED: Improve attribute error messages
96
- * FIXED: Refactor Baggage to remove Noop*
97
- * FIXED: Support OTEL_SERVICE_NAME env var
98
- * FIXED: Remove unnecessary readers from SDK Tracer
99
- * FIXED: Total order constraint on span.status=
100
- * FIXED: Flakey tracer provider test
101
- * FIXED: Split lock in TracerProvider
102
- * FIXED: Span limits env vars
103
- * FIXED: Prune invalid links
104
- * DOCS: Update docs to rely more on environment variable configuration
97
+ - BREAKING CHANGE: Remove optional parent_context from in_span
98
+ - BREAKING CHANGE: Replace Time.now with Process.clock_gettime
99
+ - BREAKING CHANGE: Refactor Baggage to remove Noop\*
100
+ - BREAKING CHANGE: Remove unnecessary readers from SDK Tracer
101
+ - BREAKING CHANGE: Total order constraint on span.status=
102
+ - BREAKING CHANGE: Use auto-generated resource constants in sdk and resource_detectors
103
+ - BREAKING CHANGE: Span limits env vars
104
+
105
+ - ADDED: Add Tracer.non_recording_span to API
106
+ - ADDED: Add unnamed tracer warning message
107
+ - ADDED: Allow disabling of install messages
108
+ - ADDED: Make API's NoopTextMapPropagator private
109
+ - ADDED: Use auto-generated resource constants in sdk and resource_detectors
110
+ - ADDED: Allow selecting multiple exporter
111
+ - ADDED: Add explicit BSP export error
112
+ - FIXED: Remove optional parent_context from in_span
113
+ - FIXED: Replace Time.now with Process.clock_gettime
114
+ - FIXED: Rename cloud.zone to cloud.availability_zone
115
+ - FIXED: Improve attribute error messages
116
+ - FIXED: Refactor Baggage to remove Noop\*
117
+ - FIXED: Support OTEL_SERVICE_NAME env var
118
+ - FIXED: Remove unnecessary readers from SDK Tracer
119
+ - FIXED: Total order constraint on span.status=
120
+ - FIXED: Flakey tracer provider test
121
+ - FIXED: Split lock in TracerProvider
122
+ - FIXED: Span limits env vars
123
+ - FIXED: Prune invalid links
124
+ - DOCS: Update docs to rely more on environment variable configuration
105
125
 
106
126
  ### v1.0.0.rc2 / 2021-06-23
107
127
 
108
- * BREAKING CHANGE: Remove optional parent_context from in_span [729](https://github.com/open-telemetry/opentelemetry-ruby/pull/729)
109
- * BREAKING CHANGE: Replace Time.now with Process.clock_gettime [717](https://github.com/open-telemetry/opentelemetry-ruby/pull/717)
110
- * BREAKING CHANGE: Refactor Baggage to remove Noop* [800](https://github.com/open-telemetry/opentelemetry-ruby/pull/800)
111
- * BREAKING CHANGE: Remove unnecessary readers from SDK Tracer [820](https://github.com/open-telemetry/opentelemetry-ruby/pull/820)
128
+ - BREAKING CHANGE: Remove optional parent_context from in_span [729](https://github.com/open-telemetry/opentelemetry-ruby/pull/729)
129
+ - BREAKING CHANGE: Replace Time.now with Process.clock_gettime [717](https://github.com/open-telemetry/opentelemetry-ruby/pull/717)
130
+ - BREAKING CHANGE: Refactor Baggage to remove Noop\* [800](https://github.com/open-telemetry/opentelemetry-ruby/pull/800)
131
+ - BREAKING CHANGE: Remove unnecessary readers from SDK Tracer [820](https://github.com/open-telemetry/opentelemetry-ruby/pull/820)
112
132
  - Tracer no longer surfaces attribute readers for the name, version, or tracer_provider
113
- * BREAKING CHANGE: Total order constraint on span.status= [805](https://github.com/open-telemetry/opentelemetry-ruby/pull/805)
133
+ - BREAKING CHANGE: Total order constraint on span.status= [805](https://github.com/open-telemetry/opentelemetry-ruby/pull/805)
114
134
 
115
- * ADDED: Add Tracer.non_recording_span to API [799](https://github.com/open-telemetry/opentelemetry-ruby/pull/799)
116
- * ADDED: Add unnamed tracer warning message [830](https://github.com/open-telemetry/opentelemetry-ruby/pull/830)
117
- * ADDED: Allow disabling of install messages [831](https://github.com/open-telemetry/opentelemetry-ruby/pull/831)
118
- * FIXED: Rename cloud.zone to cloud.availability_zone [734](https://github.com/open-telemetry/opentelemetry-ruby/pull/734)
119
- * FIXED: Improve attribute error messages [742](https://github.com/open-telemetry/opentelemetry-ruby/pull/742)
120
- * FIXED: Support OTEL_SERVICE_NAME env var [806]https://github.com/open-telemetry/opentelemetry-ruby/pull/806
121
- * FIXED: Flakey tracer provider test
135
+ - ADDED: Add Tracer.non_recording_span to API [799](https://github.com/open-telemetry/opentelemetry-ruby/pull/799)
136
+ - ADDED: Add unnamed tracer warning message [830](https://github.com/open-telemetry/opentelemetry-ruby/pull/830)
137
+ - ADDED: Allow disabling of install messages [831](https://github.com/open-telemetry/opentelemetry-ruby/pull/831)
138
+ - FIXED: Rename cloud.zone to cloud.availability_zone [734](https://github.com/open-telemetry/opentelemetry-ruby/pull/734)
139
+ - FIXED: Improve attribute error messages [742](https://github.com/open-telemetry/opentelemetry-ruby/pull/742)
140
+ - FIXED: Support OTEL_SERVICE_NAME env var [806]https://github.com/open-telemetry/opentelemetry-ruby/pull/806
141
+ - FIXED: Flakey tracer provider test
122
142
 
123
143
  ### v1.0.0.rc1 / 2021-05-21
124
144
 
125
- * BREAKING CHANGE: Remove optional parent_context from in_span
126
- * BREAKING CHANGE: Replace Time.now with Process.clock_gettime
145
+ - BREAKING CHANGE: Remove optional parent_context from in_span
146
+ - BREAKING CHANGE: Replace Time.now with Process.clock_gettime
127
147
 
128
- * FIXED: Remove optional parent_context from in_span
129
- * FIXED: Replace Time.now with Process.clock_gettime
130
- * FIXED: Rename cloud.zone to cloud.availability_zone
131
- * FIXED: Improve attribute error messages
148
+ - FIXED: Remove optional parent_context from in_span
149
+ - FIXED: Replace Time.now with Process.clock_gettime
150
+ - FIXED: Rename cloud.zone to cloud.availability_zone
151
+ - FIXED: Improve attribute error messages
132
152
 
133
153
  ### v0.17.0 / 2021-04-22
134
154
 
135
- * BREAKING CHANGE: Replace TextMapInjector/TextMapExtractor pairs with a TextMapPropagator.
155
+ - BREAKING CHANGE: Replace TextMapInjector/TextMapExtractor pairs with a TextMapPropagator.
136
156
 
137
157
  [Check the propagator documentation](https://open-telemetry.github.io/opentelemetry-ruby/) for the new usage.
138
158
 
139
- * ADDED: Add zipkin exporter
140
- * ADDED: Processors validate exporters on init.
141
- * ADDED: Add configurable truncation of span and event attribute values
142
- * ADDED: Add simple 'recording' attr_accessor to InMemorySpanExporter
143
- * FIXED: Typo in error message
144
- * FIXED: Improve configuration error reporting
145
- * FIXED: Refactor propagators to add #fields
159
+ - ADDED: Add zipkin exporter
160
+ - ADDED: Processors validate exporters on init.
161
+ - ADDED: Add configurable truncation of span and event attribute values
162
+ - ADDED: Add simple 'recording' attr_accessor to InMemorySpanExporter
163
+ - FIXED: Typo in error message
164
+ - FIXED: Improve configuration error reporting
165
+ - FIXED: Refactor propagators to add #fields
146
166
 
147
167
  ### v0.16.0 / 2021-03-17
148
168
 
149
- * BREAKING CHANGE: Update SDK BaggageManager to match API
150
- * BREAKING CHANGE: Implement Exporter#force_flush
169
+ - BREAKING CHANGE: Update SDK BaggageManager to match API
170
+ - BREAKING CHANGE: Implement Exporter#force_flush
151
171
 
152
- * ADDED: Add force_flush to SDK's TracerProvider
153
- * ADDED: Add k8s node to gcp resource detector
154
- * ADDED: Add console option for OTEL_TRACES_EXPORTER
155
- * ADDED: Span#add_attributes
156
- * ADDED: Implement Exporter#force_flush
157
- * FIXED: Update SDK BaggageManager to match API
158
- * DOCS: Replace Gitter with GitHub Discussions
172
+ - ADDED: Add force_flush to SDK's TracerProvider
173
+ - ADDED: Add k8s node to gcp resource detector
174
+ - ADDED: Add console option for OTEL_TRACES_EXPORTER
175
+ - ADDED: Span#add_attributes
176
+ - ADDED: Implement Exporter#force_flush
177
+ - FIXED: Update SDK BaggageManager to match API
178
+ - DOCS: Replace Gitter with GitHub Discussions
159
179
 
160
180
  ### v0.15.0 / 2021-02-18
161
181
 
162
- * BREAKING CHANGE: Streamline processor pipeline
182
+ - BREAKING CHANGE: Streamline processor pipeline
163
183
 
164
- * ADDED: Add instrumentation config validation
165
- * FIXED: Streamline processor pipeline
166
- * FIXED: OTEL_TRACE -> OTEL_TRACES env vars
167
- * FIXED: Change limits from 1000 to 128
168
- * FIXED: OTEL_TRACES_EXPORTER and OTEL_PROPAGATORS
169
- * FIXED: Add thread error handling to the BSP
170
- * DOCS: Clarify nil attribute values not allowed
184
+ - ADDED: Add instrumentation config validation
185
+ - FIXED: Streamline processor pipeline
186
+ - FIXED: OTEL_TRACE -> OTEL_TRACES env vars
187
+ - FIXED: Change limits from 1000 to 128
188
+ - FIXED: OTEL_TRACES_EXPORTER and OTEL_PROPAGATORS
189
+ - FIXED: Add thread error handling to the BSP
190
+ - DOCS: Clarify nil attribute values not allowed
171
191
 
172
192
  ### v0.14.0 / 2021-02-03
173
193
 
174
- * BREAKING CHANGE: Replace getter and setter callables and remove rack specific propagators
194
+ - BREAKING CHANGE: Replace getter and setter callables and remove rack specific propagators
175
195
 
176
- * ADDED: Replace getter and setter callables and remove rack specific propagators
196
+ - ADDED: Replace getter and setter callables and remove rack specific propagators
177
197
 
178
198
  ### v0.13.1 / 2021-02-01
179
199
 
180
- * FIXED: Leaky test
181
- * FIXED: Allow env var override of service.name
200
+ - FIXED: Leaky test
201
+ - FIXED: Allow env var override of service.name
182
202
 
183
203
  ### v0.13.0 / 2021-01-29
184
204
 
185
- * BREAKING CHANGE: Remove MILLIS from BatchSpanProcessor vars
205
+ - BREAKING CHANGE: Remove MILLIS from BatchSpanProcessor vars
186
206
 
187
- * ADDED: Process.runtime resource
188
- * ADDED: Provide default resource in SDK
189
- * ADDED: Add optional attributes to record_exception
190
- * FIXED: Resource.merge consistency
191
- * FIXED: Remove MILLIS from BatchSpanProcessor vars
207
+ - ADDED: Process.runtime resource
208
+ - ADDED: Provide default resource in SDK
209
+ - ADDED: Add optional attributes to record_exception
210
+ - FIXED: Resource.merge consistency
211
+ - FIXED: Remove MILLIS from BatchSpanProcessor vars
192
212
 
193
213
  ### v0.12.1 / 2021-01-13
194
214
 
195
- * FIXED: Fix several BatchSpanProcessor errors related to fork safety
196
- * FIXED: Define default value for traceid ratio
215
+ - FIXED: Fix several BatchSpanProcessor errors related to fork safety
216
+ - FIXED: Define default value for traceid ratio
197
217
 
198
218
  ### v0.12.0 / 2020-12-24
199
219
 
200
- * ADDED: Structured error handling
201
- * ADDED: Pluggable ID generation
202
- * FIXED: BSP dropped span buffer full reporting
203
- * FIXED: Implement SDK environment variables
204
- * FIXED: Remove incorrect TODO
220
+ - ADDED: Structured error handling
221
+ - ADDED: Pluggable ID generation
222
+ - FIXED: BSP dropped span buffer full reporting
223
+ - FIXED: Implement SDK environment variables
224
+ - FIXED: Remove incorrect TODO
205
225
 
206
226
  ### v0.11.1 / 2020-12-16
207
227
 
208
- * FIXED: BSP dropped span buffer full reporting
228
+ - FIXED: BSP dropped span buffer full reporting
209
229
 
210
230
  ### v0.11.0 / 2020-12-11
211
231
 
212
- * ADDED: Metrics reporting from trace export
213
- * FIXED: Copyright comments to not reference year
232
+ - ADDED: Metrics reporting from trace export
233
+ - FIXED: Copyright comments to not reference year
214
234
 
215
235
  ### v0.10.0 / 2020-12-03
216
236
 
217
- * BREAKING CHANGE: Allow samplers to modify tracestate
237
+ - BREAKING CHANGE: Allow samplers to modify tracestate
218
238
 
219
- * FIXED: Allow samplers to modify tracestate
239
+ - FIXED: Allow samplers to modify tracestate
220
240
 
221
241
  ### v0.9.0 / 2020-11-27
222
242
 
223
- * BREAKING CHANGE: Pass full Context to samplers
224
- * BREAKING CHANGE: Add timeout for force_flush and shutdown
243
+ - BREAKING CHANGE: Pass full Context to samplers
244
+ - BREAKING CHANGE: Add timeout for force_flush and shutdown
225
245
 
226
- * ADDED: Add OTEL_RUBY_BSP_START_THREAD_ON_BOOT env var
227
- * ADDED: Add timeout for force_flush and shutdown
228
- * FIXED: Signal at batch_size
229
- * FIXED: SDK Span.recording? after finish
230
- * FIXED: Pass full Context to samplers
231
- * DOCS: Add documentation on usage scenarios for span processors
246
+ - ADDED: Add OTEL_RUBY_BSP_START_THREAD_ON_BOOT env var
247
+ - ADDED: Add timeout for force_flush and shutdown
248
+ - FIXED: Signal at batch_size
249
+ - FIXED: SDK Span.recording? after finish
250
+ - FIXED: Pass full Context to samplers
251
+ - DOCS: Add documentation on usage scenarios for span processors
232
252
 
233
253
  ### v0.8.0 / 2020-10-27
234
254
 
235
- * BREAKING CHANGE: Move context/span methods to Trace module
236
- * BREAKING CHANGE: Remove 'canonical' from status codes
237
- * BREAKING CHANGE: Assorted SpanContext fixes
255
+ - BREAKING CHANGE: Move context/span methods to Trace module
256
+ - BREAKING CHANGE: Remove 'canonical' from status codes
257
+ - BREAKING CHANGE: Assorted SpanContext fixes
238
258
 
239
- * FIXED: Move context/span methods to Trace module
240
- * FIXED: Remove 'canonical' from status codes
241
- * FIXED: Assorted SpanContext fixes
259
+ - FIXED: Move context/span methods to Trace module
260
+ - FIXED: Remove 'canonical' from status codes
261
+ - FIXED: Assorted SpanContext fixes
242
262
 
243
263
  ### v0.7.0 / 2020-10-07
244
264
 
245
- * ADDED: Add service_name setter to configurator
246
- * ADDED: Add service_version setter to configurator
247
- * FIXED: Fork safety for batch processor
248
- * FIXED: Don't generate a span ID unnecessarily
249
- * DOCS: Fix Configurator#add_span_processor
250
- * DOCS: Standardize toplevel docs structure and readme
265
+ - ADDED: Add service_name setter to configurator
266
+ - ADDED: Add service_version setter to configurator
267
+ - FIXED: Fork safety for batch processor
268
+ - FIXED: Don't generate a span ID unnecessarily
269
+ - DOCS: Fix Configurator#add_span_processor
270
+ - DOCS: Standardize toplevel docs structure and readme
251
271
 
252
272
  ### v0.6.0 / 2020-09-10
253
273
 
254
- * BREAKING CHANGE: Rename Resource labels to attributes
255
- * BREAKING CHANGE: Export resource from Span/SpanData instead of library_resource
256
- * BREAKING CHANGE: Rename CorrelationContext to Baggage
257
- * BREAKING CHANGE: Rename Text* to TextMap* (propagators, injectors, extractors)
258
- * BREAKING CHANGE: Rename span.record_error to span.record_exception
259
- * BREAKING CHANGE: Update samplers to match spec
260
- * BREAKING CHANGE: Remove support for lazy event creation
261
-
262
- * ADDED: Add OTLP exporter
263
- * ADDED: Add support for OTEL_LOG_LEVEL env var
264
- * FIXED: Rename Resource labels to attributes
265
- * ADDED: Environment variable resource detection
266
- * ADDED: BatchSpanProcessor environment variable support
267
- * FIXED: Remove semver prefix
268
- * FIXED: Docs for array valued attributes
269
- * ADDED: Add hex_trace_id and hex_span_id helpers to SpanData
270
- * FIXED: Fix ProbabilitySampler
271
- * ADDED: Implement GetCorrelations
272
- * FIXED: Change default Sampler to ParentOrElse(AlwaysOn)
273
- * FIXED: Fix probability sampler
274
+ - BREAKING CHANGE: Rename Resource labels to attributes
275
+ - BREAKING CHANGE: Export resource from Span/SpanData instead of library_resource
276
+ - BREAKING CHANGE: Rename CorrelationContext to Baggage
277
+ - BREAKING CHANGE: Rename Text* to TextMap* (propagators, injectors, extractors)
278
+ - BREAKING CHANGE: Rename span.record_error to span.record_exception
279
+ - BREAKING CHANGE: Update samplers to match spec
280
+ - BREAKING CHANGE: Remove support for lazy event creation
281
+
282
+ - ADDED: Add OTLP exporter
283
+ - ADDED: Add support for OTEL_LOG_LEVEL env var
284
+ - FIXED: Rename Resource labels to attributes
285
+ - ADDED: Environment variable resource detection
286
+ - ADDED: BatchSpanProcessor environment variable support
287
+ - FIXED: Remove semver prefix
288
+ - FIXED: Docs for array valued attributes
289
+ - ADDED: Add hex_trace_id and hex_span_id helpers to SpanData
290
+ - FIXED: Fix ProbabilitySampler
291
+ - ADDED: Implement GetCorrelations
292
+ - FIXED: Change default Sampler to ParentOrElse(AlwaysOn)
293
+ - FIXED: Fix probability sampler
@@ -93,7 +93,7 @@ module OpenTelemetry
93
93
  end
94
94
 
95
95
  # Returns a new, merged {Resource} by merging the current {Resource} with
96
- # the other {Resource}. In case of a collision, the current {Resource}
96
+ # the other {Resource}. In case of a collision, the other {Resource}
97
97
  # takes precedence
98
98
  #
99
99
  # @param [Resource] other The other resource to merge
@@ -81,7 +81,7 @@ module OpenTelemetry
81
81
  # Must be within [0.0, 1.0].
82
82
  # @raise [ArgumentError] if ratio is out of range
83
83
  def self.trace_id_ratio_based(ratio)
84
- raise ArgumentError, 'ratio must be in range [0.0, 1.0]' unless (0.0..1.0).include?(ratio)
84
+ raise ArgumentError, 'ratio must be in range [0.0, 1.0]' unless (0.0..1.0).cover?(ratio)
85
85
 
86
86
  TraceIdRatioBased.new(ratio)
87
87
  end
@@ -312,17 +312,19 @@ module OpenTelemetry
312
312
  context.span_id,
313
313
  context.trace_id,
314
314
  context.trace_flags,
315
- context.tracestate
315
+ context.tracestate,
316
+ @parent_span_is_remote
316
317
  )
317
318
  end
318
319
 
319
320
  # @api private
320
- def initialize(context, parent_context, parent_span, name, kind, parent_span_id, span_limits, span_processors, attributes, links, start_timestamp, resource, instrumentation_scope) # rubocop:disable Metrics/MethodLength, Metrics/PerceivedComplexity
321
+ def initialize(context, parent_context, parent_span, name, kind, parent_span_id, span_limits, span_processors, attributes, links, start_timestamp, resource, instrumentation_scope) # rubocop:disable Metrics/MethodLength, Metrics/PerceivedComplexity, Metrics/CyclomaticComplexity
321
322
  super(span_context: context)
322
323
  @mutex = Mutex.new
323
324
  @name = name
324
325
  @kind = kind
325
326
  @parent_span_id = parent_span_id.freeze || OpenTelemetry::Trace::INVALID_SPAN_ID
327
+ @parent_span_is_remote = parent_span&.context&.remote? || false
326
328
  @span_limits = span_limits
327
329
  @span_processors = span_processors
328
330
  @resource = resource
@@ -27,7 +27,8 @@ module OpenTelemetry
27
27
  :span_id, # String (8 byte binary)
28
28
  :trace_id, # String (16-byte binary)
29
29
  :trace_flags, # Integer (8-bit byte of bit flags)
30
- :tracestate) do # OpenTelemetry::Trace::Tracestate
30
+ :tracestate, # OpenTelemetry::Trace::Tracestate
31
+ :parent_span_is_remote) do # Boolean (whether parent span context is remote)
31
32
  # Returns the lowercase [hex encoded](https://tools.ietf.org/html/rfc4648#section-8) span ID.
32
33
  #
33
34
  # @return [String] A 16-hex-character lowercase string.
@@ -7,6 +7,6 @@
7
7
  module OpenTelemetry
8
8
  module SDK
9
9
  ## Current OpenTelemetry version
10
- VERSION = '1.6.0'
10
+ VERSION = '1.10.0'
11
11
  end
12
12
  end
@@ -61,6 +61,11 @@ module OpenTelemetry
61
61
  # c.use_all
62
62
  # end
63
63
  def configure
64
+ if ENV['OTEL_SDK_DISABLED'] == 'true'
65
+ OpenTelemetry.logger.warn 'Environment variable OTEL_SDK_DISABLED is defined as true. SDK is disabled.'
66
+ return
67
+ end
68
+
64
69
  configurator = Configurator.new
65
70
  yield configurator if block_given?
66
71
  configurator.configure
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: opentelemetry-sdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.0
4
+ version: 1.10.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - OpenTelemetry Authors
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-12-05 00:00:00.000000000 Z
11
+ date: 2025-10-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: opentelemetry-api
@@ -100,28 +100,28 @@ dependencies:
100
100
  requirements:
101
101
  - - "~>"
102
102
  - !ruby/object:Gem::Version
103
- version: 5.15.0
103
+ version: '5.0'
104
104
  type: :development
105
105
  prerelease: false
106
106
  version_requirements: !ruby/object:Gem::Requirement
107
107
  requirements:
108
108
  - - "~>"
109
109
  - !ruby/object:Gem::Version
110
- version: 5.15.0
110
+ version: '5.0'
111
111
  - !ruby/object:Gem::Dependency
112
112
  name: opentelemetry-exporter-zipkin
113
113
  requirement: !ruby/object:Gem::Requirement
114
114
  requirements:
115
115
  - - "~>"
116
116
  - !ruby/object:Gem::Version
117
- version: 0.19.0
117
+ version: '0.19'
118
118
  type: :development
119
119
  prerelease: false
120
120
  version_requirements: !ruby/object:Gem::Requirement
121
121
  requirements:
122
122
  - - "~>"
123
123
  - !ruby/object:Gem::Version
124
- version: 0.19.0
124
+ version: '0.19'
125
125
  - !ruby/object:Gem::Dependency
126
126
  name: opentelemetry-instrumentation-base
127
127
  requirement: !ruby/object:Gem::Requirement
@@ -294,11 +294,11 @@ homepage: https://github.com/open-telemetry/opentelemetry-ruby
294
294
  licenses:
295
295
  - Apache-2.0
296
296
  metadata:
297
- changelog_uri: https://open-telemetry.github.io/opentelemetry-ruby/opentelemetry-sdk/v1.6.0/file.CHANGELOG.html
297
+ changelog_uri: https://open-telemetry.github.io/opentelemetry-ruby/opentelemetry-sdk/v1.10.0/file.CHANGELOG.html
298
298
  source_code_uri: https://github.com/open-telemetry/opentelemetry-ruby/tree/main/sdk
299
299
  bug_tracker_uri: https://github.com/open-telemetry/opentelemetry-ruby/issues
300
- documentation_uri: https://open-telemetry.github.io/opentelemetry-ruby/opentelemetry-sdk/v1.6.0
301
- post_install_message:
300
+ documentation_uri: https://open-telemetry.github.io/opentelemetry-ruby/opentelemetry-sdk/v1.10.0
301
+ post_install_message:
302
302
  rdoc_options: []
303
303
  require_paths:
304
304
  - lib
@@ -306,15 +306,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
306
306
  requirements:
307
307
  - - ">="
308
308
  - !ruby/object:Gem::Version
309
- version: '3.0'
309
+ version: '3.1'
310
310
  required_rubygems_version: !ruby/object:Gem::Requirement
311
311
  requirements:
312
312
  - - ">="
313
313
  - !ruby/object:Gem::Version
314
314
  version: '0'
315
315
  requirements: []
316
- rubygems_version: 3.2.33
317
- signing_key:
316
+ rubygems_version: 3.3.27
317
+ signing_key:
318
318
  specification_version: 4
319
319
  summary: A stats collection and distributed tracing framework
320
320
  test_files: []