Skip to content

Commit 68ce4bc

Browse files
authored
Merge branch 'main' into issue-1527
2 parents 8a36aed + 6952f29 commit 68ce4bc

File tree

26 files changed

+142
-58
lines changed

26 files changed

+142
-58
lines changed

.github/workflows/ci.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -141,4 +141,4 @@ jobs:
141141
- name: Upload to codecov.io
142142
uses: codecov/codecov-action@v3
143143
with:
144-
fail_ci_if_error: true
144+
fail_ci_if_error: false

LICENSE

+1-1
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@
186186
same "printed page" as the copyright notice for easier
187187
identification within third-party archives.
188188

189-
Copyright The OpenTelemetry Authors
189+
Copyright [yyyy] [name of copyright owner]
190190

191191
Licensed under the Apache License, Version 2.0 (the "License");
192192
you may not use this file except in compliance with the License.

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -192,11 +192,11 @@ For GitHub groups see the [code owners](CODEOWNERS) file.
192192
* [Cijo Thomas](https://github.com/cijothomas)
193193
* [Harold Dost](https://github.com/hdost)
194194
* [Julian Tescher](https://github.com/jtescher)
195+
* [Lalit Kumar Bhasin](https://github.com/lalitb)
195196
* [Zhongyang Wu](https://github.com/TommyCpp)
196197

197198
### Approvers
198199

199-
* [Lalit Kumar Bhasin](https://github.com/lalitb)
200200
* [Shaun Cox](https://github.com/shaun-cox)
201201

202202
### Emeritus

opentelemetry-appender-log/LICENSE

+1-1
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@
186186
same "printed page" as the copyright notice for easier
187187
identification within third-party archives.
188188

189-
Copyright 2023 The OpenTelemetry Authors
189+
Copyright [yyyy] [name of copyright owner]
190190

191191
Licensed under the Apache License, Version 2.0 (the "License");
192192
you may not use this file except in compliance with the License.

opentelemetry-http/CHANGELOG.md

+2
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
## vNext
44

5+
- Add `reqwest-rustls-webkpi-roots` feature flag to configure [`reqwest`](https://docs.rs/reqwest/0.11.27/reqwest/index.html#optional-features) to use embedded `webkpi-roots`.
6+
57
## v0.11.1
68

79
- Add feature flag enabling users to configure `reqwest` usage to use rustls via

opentelemetry-http/Cargo.toml

+1
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ rust-version = "1.65"
1111

1212
[features]
1313
reqwest-rustls = ["reqwest", "reqwest/rustls-tls-native-roots"]
14+
reqwest-rustls-webkpi-roots = ["reqwest", "reqwest/rustls-tls-webpki-roots"]
1415

1516
[dependencies]
1617
async-trait = { workspace = true }

opentelemetry-http/LICENSE

+1-1
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@
186186
same "printed page" as the copyright notice for easier
187187
identification within third-party archives.
188188

189-
Copyright 2023 The OpenTelemetry Authors
189+
Copyright [yyyy] [name of copyright owner]
190190

191191
Licensed under the Apache License, Version 2.0 (the "License");
192192
you may not use this file except in compliance with the License.

opentelemetry-jaeger-propagator/LICENSE

+1-1
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@
186186
same "printed page" as the copyright notice for easier
187187
identification within third-party archives.
188188

189-
Copyright 2023 The OpenTelemetry Authors
189+
Copyright [yyyy] [name of copyright owner]
190190

191191
Licensed under the Apache License, Version 2.0 (the "License");
192192
you may not use this file except in compliance with the License.

opentelemetry-jaeger/LICENSE

+1-1
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@
186186
same "printed page" as the copyright notice for easier
187187
identification within third-party archives.
188188

189-
Copyright 2023 The OpenTelemetry Authors
189+
Copyright [yyyy] [name of copyright owner]
190190

191191
Licensed under the Apache License, Version 2.0 (the "License");
192192
you may not use this file except in compliance with the License.

opentelemetry-otlp/CHANGELOG.md

+1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
### Added
1010

1111
- Added `DeltaTemporalitySelector` ([#1568])
12+
- Add `webkpi-roots` features to `reqwest` and `tonic` backends
1213

1314
[#1568]: https://github.com/open-telemetry/opentelemetry-rust/pull/1568
1415

opentelemetry-otlp/Cargo.toml

+3-1
Original file line numberDiff line numberDiff line change
@@ -67,12 +67,14 @@ grpc-tonic = ["tonic", "prost", "http", "tokio", "opentelemetry-proto/gen-tonic"
6767
gzip-tonic = ["tonic/gzip"]
6868
tls = ["tonic/tls"]
6969
tls-roots = ["tls", "tonic/tls-roots"]
70+
tls-webkpi-roots = ["tls", "tonic/tls-webpki-roots"]
7071

7172
# http binary
7273
http-proto = ["prost", "opentelemetry-http", "opentelemetry-proto/gen-tonic-messages", "http", "trace", "metrics"]
7374
reqwest-blocking-client = ["reqwest/blocking", "opentelemetry-http/reqwest"]
7475
reqwest-client = ["reqwest", "opentelemetry-http/reqwest"]
75-
reqwest-rustls = ["reqwest", "reqwest/rustls-tls-native-roots"]
76+
reqwest-rustls = ["reqwest", "opentelemetry-http/reqwest-rustls"]
77+
reqwest-rustls-webkpi-roots = ["reqwest", "opentelemetry-http/reqwest-rustls-webkpi-roots"]
7678

7779
# test
7880
integration-testing = ["tonic", "prost", "tokio/full", "trace"]

opentelemetry-otlp/LICENSE

+1-1
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@
186186
same "printed page" as the copyright notice for easier
187187
identification within third-party archives.
188188

189-
Copyright 2023 The OpenTelemetry Authors
189+
Copyright [yyyy] [name of copyright owner]
190190

191191
Licensed under the Apache License, Version 2.0 (the "License");
192192
you may not use this file except in compliance with the License.

opentelemetry-otlp/src/lib.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -97,13 +97,15 @@
9797
//! * `gzip-tonic`: Use gzip compression for `tonic` grpc layer.
9898
//! * `tls-tonic`: Enable TLS.
9999
//! * `tls-roots`: Adds system trust roots to rustls-based gRPC clients using the rustls-native-certs crate
100+
//! * `tls-webkpi-roots`: Embeds Mozilla's trust roots to rustls-based gRPC clients using the webkpi-roots crate
100101
//!
101102
//! The following feature flags offer additional configurations on http:
102103
//!
103104
//! * `http-proto`: Use http as transport layer, protobuf as body format.
104105
//! * `reqwest-blocking-client`: Use reqwest blocking http client.
105106
//! * `reqwest-client`: Use reqwest http client.
106-
//! * `reqwest-rustls`: Use reqwest with TLS.
107+
//! * `reqwest-rustls`: Use reqwest with TLS with system trust roots via `rustls-native-certs` crate.
108+
//! * `reqwest-rustls-webkpi-roots`: Use reqwest with TLS with Mozilla's trust roots via `webkpi-roots` crate.
107109
//!
108110
//! # Kitchen Sink Full Configuration
109111
//!

opentelemetry-prometheus/LICENSE

+1-1
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@
186186
same "printed page" as the copyright notice for easier
187187
identification within third-party archives.
188188

189-
Copyright 2023 The OpenTelemetry Authors
189+
Copyright [yyyy] [name of copyright owner]
190190

191191
Licensed under the Apache License, Version 2.0 (the "License");
192192
you may not use this file except in compliance with the License.

opentelemetry-proto/CHANGELOG.md

+2
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
## vNext
44

5+
- Update protobuf definitions to v1.1.0 [#1668](https://github.com/open-telemetry/opentelemetry-rust/pull/1668)
6+
57
## v0.5.0
68

79
### Changed

opentelemetry-proto/LICENSE

+1-1
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@
186186
same "printed page" as the copyright notice for easier
187187
identification within third-party archives.
188188

189-
Copyright 2023 The OpenTelemetry Authors
189+
Copyright [yyyy] [name of copyright owner]
190190

191191
Licensed under the Apache License, Version 2.0 (the "License");
192192
you may not use this file except in compliance with the License.

opentelemetry-proto/src/proto/tonic/opentelemetry.proto.metrics.v1.rs

+9
Original file line numberDiff line numberDiff line change
@@ -168,6 +168,15 @@ pub struct Metric {
168168
/// described by <http://unitsofmeasure.org/ucum.html.>
169169
#[prost(string, tag = "3")]
170170
pub unit: ::prost::alloc::string::String,
171+
/// Additional metadata attributes that describe the metric. \[Optional\].
172+
/// Attributes are non-identifying.
173+
/// Consumers SHOULD NOT need to be aware of these attributes.
174+
/// These attributes MAY be used to encode information allowing
175+
/// for lossless roundtrip translation to / from another data model.
176+
/// Attribute keys MUST be unique (it is not allowed to have more than one
177+
/// attribute with the same key).
178+
#[prost(message, repeated, tag = "12")]
179+
pub metadata: ::prost::alloc::vec::Vec<super::super::common::v1::KeyValue>,
171180
/// Data determines the aggregation type (if any) of the metric, what is the
172181
/// reported value type for the data points, as well as the relatationship to
173182
/// the time interval over which they are reported.

opentelemetry-proto/src/proto/tonic/opentelemetry.proto.trace.v1.rs

+38-13
Original file line numberDiff line numberDiff line change
@@ -125,20 +125,27 @@ pub struct Span {
125125
)
126126
)]
127127
pub parent_span_id: ::prost::alloc::vec::Vec<u8>,
128-
/// Flags, a bit field. 8 least significant bits are the trace
129-
/// flags as defined in W3C Trace Context specification. Readers
130-
/// MUST not assume that 24 most significant bits will be zero.
131-
/// To read the 8-bit W3C trace flag, use `flags & SPAN_FLAGS_TRACE_FLAGS_MASK`.
128+
/// Flags, a bit field.
129+
///
130+
/// Bits 0-7 (8 least significant bits) are the trace flags as defined in W3C Trace
131+
/// Context specification. To read the 8-bit W3C trace flag, use
132+
/// `flags & SPAN_FLAGS_TRACE_FLAGS_MASK`.
133+
///
134+
/// See <https://www.w3.org/TR/trace-context-2/#trace-flags> for the flag definitions.
135+
///
136+
/// Bits 8 and 9 represent the 3 states of whether a span's parent
137+
/// is remote. The states are (unknown, is not remote, is remote).
138+
/// To read whether the value is known, use `(flags & SPAN_FLAGS_CONTEXT_HAS_IS_REMOTE_MASK) != 0`.
139+
/// To read whether the span is remote, use `(flags & SPAN_FLAGS_CONTEXT_IS_REMOTE_MASK) != 0`.
132140
///
133141
/// When creating span messages, if the message is logically forwarded from another source
134142
/// with an equivalent flags fields (i.e., usually another OTLP span message), the field SHOULD
135143
/// be copied as-is. If creating from a source that does not have an equivalent flags field
136-
/// (such as a runtime representation of an OpenTelemetry span), the high 24 bits MUST
144+
/// (such as a runtime representation of an OpenTelemetry span), the high 22 bits MUST
137145
/// be set to zero.
146+
/// Readers MUST NOT assume that bits 10-31 (22 most significant bits) will be zero.
138147
///
139148
/// \[Optional\].
140-
///
141-
/// See <https://www.w3.org/TR/trace-context-2/#trace-flags> for the flag definitions.
142149
#[prost(fixed32, tag = "16")]
143150
pub flags: u32,
144151
/// A description of the span's operation.
@@ -297,14 +304,23 @@ pub mod span {
297304
/// then no attributes were dropped.
298305
#[prost(uint32, tag = "5")]
299306
pub dropped_attributes_count: u32,
300-
/// Flags, a bit field. 8 least significant bits are the trace
301-
/// flags as defined in W3C Trace Context specification. Readers
302-
/// MUST not assume that 24 most significant bits will be zero.
303-
/// When creating new spans, the most-significant 24-bits MUST be
304-
/// zero. To read the 8-bit W3C trace flag (use flags &
305-
/// SPAN_FLAGS_TRACE_FLAGS_MASK). \[Optional\].
307+
/// Flags, a bit field.
308+
///
309+
/// Bits 0-7 (8 least significant bits) are the trace flags as defined in W3C Trace
310+
/// Context specification. To read the 8-bit W3C trace flag, use
311+
/// `flags & SPAN_FLAGS_TRACE_FLAGS_MASK`.
306312
///
307313
/// See <https://www.w3.org/TR/trace-context-2/#trace-flags> for the flag definitions.
314+
///
315+
/// Bits 8 and 9 represent the 3 states of whether the link is remote.
316+
/// The states are (unknown, is not remote, is remote).
317+
/// To read whether the value is known, use `(flags & SPAN_FLAGS_CONTEXT_HAS_IS_REMOTE_MASK) != 0`.
318+
/// To read whether the link is remote, use `(flags & SPAN_FLAGS_CONTEXT_IS_REMOTE_MASK) != 0`.
319+
///
320+
/// Readers MUST NOT assume that bits 10-31 (22 most significant bits) will be zero.
321+
/// When creating new spans, bits 10-31 (most-significant 22-bits) MUST be zero.
322+
///
323+
/// \[Optional\].
308324
#[prost(fixed32, tag = "6")]
309325
pub flags: u32,
310326
}
@@ -468,6 +484,11 @@ pub enum SpanFlags {
468484
DoNotUse = 0,
469485
/// Bits 0-7 are used for trace flags.
470486
TraceFlagsMask = 255,
487+
/// Bits 8 and 9 are used to indicate that the parent span or link span is remote.
488+
/// Bit 8 (`HAS_IS_REMOTE`) indicates whether the value is known.
489+
/// Bit 9 (`IS_REMOTE`) indicates whether the span or link is remote.
490+
ContextHasIsRemoteMask = 256,
491+
ContextIsRemoteMask = 512,
471492
}
472493
impl SpanFlags {
473494
/// String value of the enum field names used in the ProtoBuf definition.
@@ -478,13 +499,17 @@ impl SpanFlags {
478499
match self {
479500
SpanFlags::DoNotUse => "SPAN_FLAGS_DO_NOT_USE",
480501
SpanFlags::TraceFlagsMask => "SPAN_FLAGS_TRACE_FLAGS_MASK",
502+
SpanFlags::ContextHasIsRemoteMask => "SPAN_FLAGS_CONTEXT_HAS_IS_REMOTE_MASK",
503+
SpanFlags::ContextIsRemoteMask => "SPAN_FLAGS_CONTEXT_IS_REMOTE_MASK",
481504
}
482505
}
483506
/// Creates an enum from field names used in the ProtoBuf definition.
484507
pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
485508
match value {
486509
"SPAN_FLAGS_DO_NOT_USE" => Some(Self::DoNotUse),
487510
"SPAN_FLAGS_TRACE_FLAGS_MASK" => Some(Self::TraceFlagsMask),
511+
"SPAN_FLAGS_CONTEXT_HAS_IS_REMOTE_MASK" => Some(Self::ContextHasIsRemoteMask),
512+
"SPAN_FLAGS_CONTEXT_IS_REMOTE_MASK" => Some(Self::ContextIsRemoteMask),
488513
_ => None,
489514
}
490515
}

opentelemetry-proto/src/transform/metrics.rs

+1
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,7 @@ pub mod tonic {
149149
name: metric.name.to_string(),
150150
description: metric.description.to_string(),
151151
unit: metric.unit.as_str().to_string(),
152+
metadata: vec![], // internal and currently unused
152153
data: metric.data.as_any().try_into().ok(),
153154
}
154155
}

opentelemetry-sdk/LICENSE

+1-1
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@
186186
same "printed page" as the copyright notice for easier
187187
identification within third-party archives.
188188

189-
Copyright 2023 The OpenTelemetry Authors
189+
Copyright [yyyy] [name of copyright owner]
190190

191191
Licensed under the Apache License, Version 2.0 (the "License");
192192
you may not use this file except in compliance with the License.

0 commit comments

Comments
 (0)