opentelemetry-propagator-ottrace 0.21.0 → 0.21.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 14db3a0c0374ca4573529297d3ea1b3c2349882a82b7cc2e0464657aa4936579
4
- data.tar.gz: afc84d4a0af4619a89ede478fc7609ffe549c871cbbf6106c64c8e683e092f4d
3
+ metadata.gz: edf917794b9e372bdf9d8bf6a8aee00b67c98d31a918c8d1f478304fc6856e42
4
+ data.tar.gz: e5868bbbd7e2b0d5c0cbe68e56fbf259f68522d95358063a1683084e8174dbbb
5
5
  SHA512:
6
- metadata.gz: 2c3e85840f70d7d139e73e46461bd637c7c41e4e5173db6dc5ee723001fea80c876f9352e5346e1b6627a32726a0a3f936882503a78a9a54c1e4cb801495ab4a
7
- data.tar.gz: 93bd9785ab9c156f9b702c8aa15fce0f9dd86560657421939687657c18eebb0194e0aa979db6a6549ead2b6153cb7e90c4aca29d91a1389b08cec008698e3eec
6
+ metadata.gz: f0a211a209a385f58fe114af5bb203130993e6a0ee25d9d887137b9c78ce76b1d7417e587a88673eb2a449eb98e197e95375127f61d7ef5a0a418ccdd5a990e4
7
+ data.tar.gz: 68b90c1cbd008c8b839f7a3920390435afce32114416882f08250b2450c386347afb4f54968de1be15ae4dfc78e23ffdbbd063ef727ac9c5d16aa114bc1b4b76
data/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # Release History: opentelemetry-propagator-ottrace
2
2
 
3
+ ### v0.21.2 / 2023-11-23
4
+
5
+ * CHANGED: Applied Rubocop Performance Recommendations [#727](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/727)
6
+
7
+ ### v0.21.1 / 2023-07-19
8
+
9
+ * DOCS: Add some clarity to ottrace docs [#522](https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/522)
10
+
3
11
  ### v0.21.0 / 2023-04-17
4
12
 
5
13
  * BREAKING CHANGE: Drop support for EoL Ruby 2.7
data/README.md CHANGED
@@ -7,8 +7,8 @@ The `opentelemetry-propagator-ottrace` gem contains injectors and extractors for
7
7
 
8
8
  | Header Name | Description | Required |
9
9
  | ------------------- | -------------------------------------------------------------------------------------------------------------------------------------- | --------------------- |
10
- | `ot-tracer-traceid` | uint64 encoded as a string of 16 hex characters | yes |
11
- | `ot-tracer-spanid` | uint64 encoded as a string of 16 hex characters | yes |
10
+ | `ot-tracer-traceid` | 64-bit; 16 hex digits (extract and inject) or 128-bit; 32 hex digits (extract) | yes |
11
+ | `ot-tracer-spanid` | 64-bit; 16 hex digits | yes |
12
12
  | `ot-tracer-sampled` | boolean or bit encoded as a string with the values `'true'`,`'false'`, `'1'`, or `'0'` | no |
13
13
  | `ot-baggage-*` | repeated string to string key-value baggage items; keys are prefixed with `ot-baggage-` and the corresponding value is the raw string. | if baggage is present |
14
14
 
@@ -24,11 +24,15 @@ This issue was [fixed](https://github.com/open-telemetry/opentelemetry-go-contri
24
24
 
25
25
  ### Interop and trace ids
26
26
 
27
- The OT trace propagation format expects trace ids to be 64-bits. In order to
28
- interop with OpenTelemetry, trace ids need to be truncated to 64-bits before
29
- sending them on the wire. When truncating, the least significant (right-most)
30
- bits MUST be retained. For example, a trace id of
31
- `3c3039f4d78d5c02ee8e3e41b17ce105` would be truncated to `ee8e3e41b17ce105`.
27
+ OTTrace was changed to be interoperable with other format so it is supposed to 8 or 16 byte array values for the trace-id.
28
+
29
+ In order to do that Lightstep released a version of the OTTrace propagators in OpenTracing SDKs that left padded 64-bit headers to 128-bits using an additional 64-bit of 0s.
30
+
31
+ The reality of the world is not every application upgraded to support 16 byte array propagation format, but this propagator must still convert legacy 64-bit trace ids to match the W3C Trace Context Trace ID 16 byte array.
32
+
33
+ In addition to that it must be interoperable with legacy OTTracers, which expect 64-bit headers so this propagator truncates the value from a 128-bit to a 64-bit value before inject it into the carrier.
34
+
35
+ This propagator is compatible with 64-bit or 128-bit trace ids when extracting the parent context, however it truncates the trace ids down to 64-bit trace ids when injecting the context.
32
36
 
33
37
  ### Baggage Notes
34
38
 
@@ -116,10 +116,10 @@ module OpenTelemetry
116
116
  getter.keys(carrier).each do |carrier_key|
117
117
  baggage_key = carrier_key.start_with?(prefix) && carrier_key[prefix.length..-1]
118
118
  next unless baggage_key
119
- next unless VALID_BAGGAGE_HEADER_NAME_CHARS =~ baggage_key
119
+ next unless VALID_BAGGAGE_HEADER_NAME_CHARS.match?(baggage_key)
120
120
 
121
121
  value = getter.get(carrier, carrier_key)
122
- next unless INVALID_BAGGAGE_HEADER_VALUE_CHARS !~ value
122
+ next if INVALID_BAGGAGE_HEADER_VALUE_CHARS.match?(value)
123
123
 
124
124
  builder.set_value(baggage_key, value)
125
125
  end
@@ -15,7 +15,7 @@ module OpenTelemetry
15
15
  module Propagator
16
16
  # Namespace for OpenTelemetry OTTrace propagation
17
17
  module OTTrace
18
- VERSION = '0.21.0'
18
+ VERSION = '0.21.2'
19
19
  end
20
20
  end
21
21
  end
@@ -5,4 +5,4 @@
5
5
  # SPDX-License-Identifier: Apache-2.0
6
6
 
7
7
  require 'opentelemetry-api'
8
- require_relative './opentelemetry/propagator/ottrace'
8
+ require_relative 'opentelemetry/propagator/ottrace'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: opentelemetry-propagator-ottrace
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.21.0
4
+ version: 0.21.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - OpenTelemetry Authors
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-04-17 00:00:00.000000000 Z
11
+ date: 2023-11-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: opentelemetry-api
@@ -72,56 +72,56 @@ dependencies:
72
72
  requirements:
73
73
  - - "~>"
74
74
  - !ruby/object:Gem::Version
75
- version: 1.49.0
75
+ version: 1.57.1
76
76
  type: :development
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
80
  - - "~>"
81
81
  - !ruby/object:Gem::Version
82
- version: 1.49.0
82
+ version: 1.57.1
83
83
  - !ruby/object:Gem::Dependency
84
- name: simplecov
84
+ name: rubocop-performance
85
85
  requirement: !ruby/object:Gem::Requirement
86
86
  requirements:
87
87
  - - "~>"
88
88
  - !ruby/object:Gem::Version
89
- version: 0.22.0
89
+ version: 1.19.1
90
90
  type: :development
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
94
  - - "~>"
95
95
  - !ruby/object:Gem::Version
96
- version: 0.22.0
96
+ version: 1.19.1
97
97
  - !ruby/object:Gem::Dependency
98
- name: yard
98
+ name: simplecov
99
99
  requirement: !ruby/object:Gem::Requirement
100
100
  requirements:
101
101
  - - "~>"
102
102
  - !ruby/object:Gem::Version
103
- version: '0.9'
103
+ version: 0.22.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: '0.9'
110
+ version: 0.22.0
111
111
  - !ruby/object:Gem::Dependency
112
- name: yard-doctest
112
+ name: yard
113
113
  requirement: !ruby/object:Gem::Requirement
114
114
  requirements:
115
115
  - - "~>"
116
116
  - !ruby/object:Gem::Version
117
- version: 0.1.6
117
+ version: '0.9'
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.1.6
124
+ version: '0.9'
125
125
  description: OTTrace Context Propagation Extension for the OpenTelemetry framework
126
126
  email:
127
127
  - cncf-opentelemetry-contributors@lists.cncf.io
@@ -141,10 +141,10 @@ homepage: https://github.com/open-telemetry/opentelemetry-ruby-contrib
141
141
  licenses:
142
142
  - Apache-2.0
143
143
  metadata:
144
- changelog_uri: https://rubydoc.info/gems/opentelemetry-propagator-ottrace/0.21.0/file/CHANGELOG.md
144
+ changelog_uri: https://rubydoc.info/gems/opentelemetry-propagator-ottrace/0.21.2/file/CHANGELOG.md
145
145
  source_code_uri: https://github.com/open-telemetry/opentelemetry-ruby-contrib/tree/main/propagator/ottrace
146
146
  bug_tracker_uri: https://github.com/open-telemetry/opentelemetry-ruby-contrib/issues
147
- documentation_uri: https://rubydoc.info/gems/opentelemetry-propagator-ottrace/0.21.0
147
+ documentation_uri: https://rubydoc.info/gems/opentelemetry-propagator-ottrace/0.21.2
148
148
  post_install_message:
149
149
  rdoc_options: []
150
150
  require_paths: