Skip to content

Commit c8fdd05

Browse files
authored
Merge branch 'main' into log-attributes-update
2 parents ffeb1ec + acf16ed commit c8fdd05

File tree

279 files changed

+19074
-9698
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

279 files changed

+19074
-9698
lines changed

.cspell.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,9 @@
4949
"nocapture",
5050
"Ochtman",
5151
"opentelemetry",
52+
"OTELCOL",
5253
"OTLP",
54+
"periodicreader",
5355
"protoc",
5456
"quantile",
5557
"Redelmeier",
@@ -59,6 +61,7 @@
5961
"shoppingcart",
6062
"struct",
6163
"Tescher",
64+
"testresults",
6265
"tracerprovider",
6366
"updown",
6467
"Zhongyang",

.github/ISSUE_TEMPLATE/BUG-REPORT.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,15 +20,15 @@ body:
2020
- type: textarea
2121
id: api-version
2222
attributes:
23-
label: API Version
23+
label: OpenTelemetry API Version (i.e version of `opentelemetry` crate)
2424
description: What version of the `opentelemetry` crate are you using?
2525
placeholder: 0.x, 1.x, etc.
2626
validations:
2727
required: true
2828
- type: textarea
2929
id: sdk-version
3030
attributes:
31-
label: SDK Version
31+
label: label: OpenTelemetry SDK Version (i.e version of `opentelemetry_sdk` crate)
3232
description: What version of the `opentelemetry_sdk` crate are you using?
3333
placeholder: 0.x, 1.x, etc.
3434
validations:
@@ -39,6 +39,7 @@ body:
3939
label: What Exporter(s) are you seeing the problem on?
4040
multiple: true
4141
options:
42+
- stdout
4243
- OTLP
4344
- Zipkin
4445
- Prometheus

.github/workflows/ci.yml

Lines changed: 11 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@ on:
88
- main
99
paths-ignore:
1010
- '**.md'
11+
concurrency:
12+
group: ${{ github.workflow }}-${{ github.ref }}
13+
cancel-in-progress: true
1114
jobs:
1215
test:
1316
strategy:
@@ -22,8 +25,9 @@ jobs:
2225
- rust: stable
2326
os: macos-latest
2427
- rust: stable
25-
os: actuated-arm64-4cpu-16gb
28+
os: otel-linux-arm64
2629
runs-on: ${{ matrix.os }}
30+
continue-on-error: ${{ matrix.rust == 'beta' }}
2731
steps:
2832
- name: Free disk space
2933
if: ${{ matrix.os == 'ubuntu-latest'}}
@@ -73,39 +77,20 @@ jobs:
7377
- uses: actions/checkout@v4
7478
- uses: dtolnay/rust-toolchain@nightly
7579
with:
76-
toolchain: nightly-2024-05-01
80+
toolchain: nightly-2024-06-30
7781
components: rustfmt
7882
- name: external-type-check
7983
run: |
80-
cargo install cargo-check-external-types
84+
cargo install cargo-check-external-types@0.1.13
8185
cd ${{ matrix.example }}
8286
cargo check-external-types --config allowed-external-types.toml
83-
non-default-examples:
84-
strategy:
85-
matrix:
86-
os: [ windows-latest, ubuntu-latest ]
87-
example: [opentelemetry-otlp/examples/basic-otlp]
88-
runs-on: ${{ matrix.os }}
89-
steps:
90-
- uses: actions/checkout@v4
91-
with:
92-
submodules: true
93-
- uses: dtolnay/rust-toolchain@stable
94-
with:
95-
components: rustfmt
96-
- uses: arduino/setup-protoc@v3
97-
with:
98-
repo-token: ${{ secrets.GITHUB_TOKEN }}
99-
- name: Build
100-
run: |
101-
cd ${{ matrix.example }}
102-
cargo build --verbose
10387
msrv:
10488
strategy:
10589
matrix:
10690
os: [windows-latest, ubuntu-latest]
107-
rust: [1.65.0, 1.70.0]
91+
rust: [1.75.0]
10892
runs-on: ${{ matrix.os }}
93+
continue-on-error: true
10994
steps:
11095
- uses: actions/checkout@v4
11196
with:
@@ -131,7 +116,7 @@ jobs:
131116
runs-on: ubuntu-latest
132117
steps:
133118
- uses: actions/checkout@v4
134-
- uses: dtolnay/rust-toolchain@nightly
119+
- uses: dtolnay/rust-toolchain@stable
135120
with:
136121
components: rustfmt
137122
- uses: arduino/setup-protoc@v3
@@ -163,7 +148,7 @@ jobs:
163148
if: hashFiles('Cargo.lock') == ''
164149
run: cargo generate-lockfile
165150
- name: cargo llvm-cov
166-
run: cargo llvm-cov --locked --all-features --workspace --lcov --output-path lcov.info
151+
run: cargo llvm-cov --locked --all-features --workspace --lcov --lib --output-path lcov.info
167152
- name: Upload to codecov.io
168153
uses: codecov/codecov-action@v4
169154
env:

.github/workflows/integration_tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,5 +24,5 @@ jobs:
2424
with:
2525
components: rustfmt
2626
- uses: arduino/setup-protoc@v3
27-
- name: Run integration tests using docker compose
27+
- name: Run integration tests
2828
run: ./scripts/integration_tests.sh

.github/workflows/semver.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ env:
44
on:
55
pull_request:
66
types: [ labeled, synchronize, opened, reopened ]
7-
87
jobs:
98
semver-compliance: # This job uses the latest published crate as baseline for comparison.
109
runs-on: ubuntu-latest

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,6 @@
55
Cargo.lock
66
/.idea/
77

8-
.cosine
8+
.cosine
9+
10+
opentelemetry-otlp/tests/integration_test/result.json

CONTRIBUTING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ For a deeper discussion, see:
140140

141141
Currently, the Opentelemetry Rust SDK has two ways to handle errors. In the situation where errors are not allowed to return. One should call global error handler to process the errors. Otherwise, one should return the errors.
142142

143-
The Opentelemetry Rust SDK comes with an error type `opentelemetry::Error`. For different function, one error has been defined. All error returned by trace module MUST be wrapped in `opentelemetry::trace::TraceError`. All errors returned by metrics module MUST be wrapped in `opentelemetry::metrics::MetricsError`. All errors returned by logs module MUST be wrapped in `opentelemetry::logs::LogsError`.
143+
The Opentelemetry Rust SDK comes with an error type `opentelemetry::Error`. For different function, one error has been defined. All error returned by trace module MUST be wrapped in `opentelemetry::trace::TraceError`. All errors returned by metrics module MUST be wrapped in `opentelemetry::metrics::MetricError`. All errors returned by logs module MUST be wrapped in `opentelemetry::logs::LogsError`.
144144

145145
For users that want to implement their own exporters. It's RECOMMENDED to wrap all errors from the exporter into a crate-level error type, and implement `ExporterError` trait.
146146

@@ -169,7 +169,7 @@ It's important to regularly review and remove the `otel_unstable` flag from the
169169
The potential features include:
170170

171171
- Stable and non-experimental features that compliant to specification, and have a feature flag to minimize compilation size. Example: feature flags for signals (like `logs`, `traces`, `metrics`) and runtimes (`rt-tokio`, `rt-tokio-current-thread`, `rt-async-std`).
172-
- Stable and non-experimental features, although not part of the specification, are crucial for enhancing the tracing/log crate's functionality or boosting performance. These features are also subject to discussion and approval by the OpenTelemetry Rust Maintainers. An example of such a feature is `logs_level_enabled`.
172+
- Stable and non-experimental features, although not part of the specification, are crucial for enhancing the tracing/log crate's functionality or boosting performance. These features are also subject to discussion and approval by the OpenTelemetry Rust Maintainers.
173173

174174
All such features should adhere to naming convention `<signal>_<feature_name>`
175175

Cargo.toml

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -39,12 +39,15 @@ reqwest = { version = "0.12", default-features = false }
3939
serde = { version = "1.0", default-features = false }
4040
serde_json = "1.0"
4141
temp-env = "0.3.6"
42-
thiserror = { version = "1", default-features = false }
43-
tonic = { version = "0.12", default-features = false }
42+
thiserror = { version = "2", default-features = false }
43+
tonic = { version = "0.12.3", default-features = false }
4444
tonic-build = "0.12"
4545
tokio = { version = "1", default-features = false }
46-
tokio-stream = "0.1.1"
47-
tracing = { version = "0.1", default-features = false }
48-
tracing-core = { version = "0.1", default-features = false }
46+
tokio-stream = "0.1"
47+
# Using `tracing 0.1.40` because 0.1.39 (which is yanked) introduces the ability to set event names in macros,
48+
# required for OpenTelemetry's internal logging macros.
49+
tracing = { version = ">=0.1.40", default-features = false }
50+
# `tracing-core >=0.1.33` is required for compatibility with `tracing >=0.1.40`.
51+
tracing-core = { version = ">=0.1.33", default-features = false }
4952
tracing-subscriber = { version = "0.3", default-features = false }
5053
url = { version = "2.5", default-features = false }

README.md

Lines changed: 13 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -17,30 +17,33 @@ analysis in order to understand your software's performance and behavior. You
1717
can export and analyze them using [Prometheus], [Jaeger], and other
1818
observability tools.
1919

20-
*Compiler support: [requires `rustc` 1.65+][msrv]*
20+
*[Supported Rust Versions](#supported-rust-versions)*
2121

2222
[Prometheus]: https://prometheus.io
2323
[Jaeger]: https://www.jaegertracing.io
24-
[msrv]: #supported-rust-versions
2524

2625
## Project Status
2726

27+
The table below summarizes the overall status of each component. Some components
28+
include unstable features, which are documented in their respective crate
29+
documentation.
30+
2831
| Signal/Component | Overall Status |
2932
| -------------------- | ------------------ |
30-
| Logs-API | Beta* |
33+
| Logs-API | RC* |
3134
| Logs-SDK | Beta |
3235
| Logs-OTLP Exporter | Beta |
3336
| Logs-Appender-Tracing | Beta |
34-
| Metrics-API | Alpha |
35-
| Metrics-SDK | Alpha |
36-
| Metrics-OTLP Exporter | Alpha |
37+
| Metrics-API | RC |
38+
| Metrics-SDK | Beta |
39+
| Metrics-OTLP Exporter | Beta |
3740
| Traces-API | Beta |
3841
| Traces-SDK | Beta |
3942
| Traces-OTLP Exporter | Beta |
4043

4144
*OpenTelemetry Rust is not introducing a new end user callable Logging API.
4245
Instead, it provides [Logs Bridge
43-
API](https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/logs/bridge-api.md),
46+
API](https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/logs/api.md),
4447
that allows one to write log appenders that can bridge existing logging
4548
libraries to the OpenTelemetry log data model. The following log appenders are
4649
available:
@@ -80,7 +83,7 @@ fn main() {
8083
});
8184

8285
// Shutdown trace pipeline
83-
global::shutdown_tracer_provider();
86+
provider.shutdown().expect("TracerProvider should shutdown successfully")
8487
}
8588
```
8689

@@ -159,7 +162,7 @@ Registry](https://opentelemetry.io/ecosystem/registry/?language=rust).
159162
## Supported Rust Versions
160163

161164
OpenTelemetry is built against the latest stable release. The minimum supported
162-
version is 1.65. The current OpenTelemetry version is not guaranteed to build
165+
version is 1.75. The current OpenTelemetry version is not guaranteed to build
163166
on Rust versions earlier than the minimum supported version.
164167

165168
The current stable Rust compiler and the three most recent minor versions
@@ -198,12 +201,12 @@ you're more than welcome to participate!
198201
* [Harold Dost](https://github.com/hdost)
199202
* [Julian Tescher](https://github.com/jtescher)
200203
* [Lalit Kumar Bhasin](https://github.com/lalitb)
204+
* [Utkarsh Umesan Pillai](https://github.com/utpilla)
201205
* [Zhongyang Wu](https://github.com/TommyCpp)
202206

203207
### Approvers
204208

205209
* [Shaun Cox](https://github.com/shaun-cox)
206-
* [Utkarsh Umesan Pillai](https://github.com/utpilla)
207210

208211
### Emeritus
209212

deny.toml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,5 @@ license-files = [
2929
]
3030

3131
[advisories]
32-
ignore = [
33-
# unsoundness in indirect dependencies without a safe upgrade below
34-
"RUSTSEC-2021-0145",
35-
"RUSTSEC-2019-0036"
36-
]
3732
unmaintained = "allow"
3833
yanked = "allow"

0 commit comments

Comments
 (0)