-
Notifications
You must be signed in to change notification settings - Fork 463
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into bounded_instruments
# Conflicts: # opentelemetry-sdk/benches/metric_counter.rs # opentelemetry-sdk/src/metrics/instrument.rs # opentelemetry-sdk/src/metrics/internal/sum.rs # opentelemetry/src/metrics/instruments/counter.rs # opentelemetry/src/metrics/instruments/up_down_counter.rs # opentelemetry/src/metrics/noop.rs # stress/Cargo.toml
- Loading branch information
Showing
94 changed files
with
3,787 additions
and
1,230 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -42,7 +42,6 @@ | |
"Lalit", | ||
"msrv", | ||
"Ochtman", | ||
"openetelemetry", | ||
"opentelemetry", | ||
"OTLP", | ||
"protoc", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,25 @@ | ||
# GRPC example | ||
|
||
Example showing [Tonic] client and server interaction with OpenTelemetry context propagation. [tracing_opentelemetry](https://docs.rs/tracing-opentelemetry/0.4.0/tracing_opentelemetry/) is used to hook into the [tracing](https://github.com/tokio-rs/tracing) ecosystem, which enables drop-in replacements for [log](https://github.com/rust-lang/log) macros and an `#[instrument]` macro that will automatically add spans to your functions. | ||
Example showing [Tonic] client and server interaction with OpenTelemetry context | ||
propagation. Traces are exported to stdout. | ||
|
||
[Tonic]: https://github.com/hyperium/tonic | ||
|
||
Examples | ||
-------- | ||
## Running the example | ||
|
||
```shell | ||
# Run jaeger in background | ||
$ docker run -d -p6831:6831/udp -p6832:6832/udp -p16686:16686 jaegertracing/all-in-one:latest | ||
|
||
# Run the server | ||
# Run the server first | ||
$ cargo run --bin grpc-server | ||
|
||
# Now run the client to make a request to the server | ||
$ cargo run --bin grpc-client | ||
|
||
# View spans (see the image below) | ||
$ firefox http://localhost:16686/ | ||
``` | ||
|
||
![Jaeger UI](trace.png) | ||
Observe that the traces are exported to stdout, and that they share the same | ||
TraceId. Also, the server span would be parented to the client span. The example | ||
demonstrates how to propagate and restore OpenTelemetry context when making | ||
out-of-process calls, so as to ensure the same trace is continued in the next | ||
process. The client here initiates the trace by creating the root client span, | ||
and it propagates its context to the server. The server, extracts the context, | ||
and creates its own server span using the extracted context, ensuring both spans | ||
are correlated. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# Changelog | ||
|
||
## vNext | ||
|
||
## v0.1.0 | ||
|
||
### Added | ||
|
||
- As part of the gradual deprecation of the exporter functionality of the opentelemetry-jaeger crate, move the opentelemetry-jaeger propagator functionality to a new crate named opentelemetry-jaeger-propagator [#1487](https://github.com/open-telemetry/opentelemetry-rust/pull/1487) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
[package] | ||
name = "opentelemetry-jaeger-propagator" | ||
version = "0.1.0" | ||
description = "Jaeger propagator for OpenTelemetry" | ||
homepage = "https://github.com/open-telemetry/opentelemetry-rust/tree/main/opentelemetry-jaeger-propagator" | ||
repository = "https://github.com/open-telemetry/opentelemetry-rust/tree/main/opentelemetry-jaeger-propagator" | ||
readme = "README.md" | ||
categories = [ | ||
"development-tools::debugging", | ||
"development-tools::profiling", | ||
"asynchronous", | ||
] | ||
keywords = ["opentelemetry", "jaeger", "propagator"] | ||
license = "Apache-2.0" | ||
edition = "2021" | ||
rust-version = "1.65" | ||
|
||
|
||
[package.metadata.docs.rs] | ||
all-features = true | ||
rustdoc-args = ["--cfg", "docsrs"] | ||
|
||
[dependencies] | ||
opentelemetry = { version = "0.21", default-features = false, features = [ | ||
"trace", | ||
], path = "../opentelemetry" } | ||
|
||
tonic = { workspace = true, optional = true } | ||
prost = { version = "0.11.6", optional = true } | ||
prost-types = { version = "0.11.6", optional = true } | ||
|
||
[dev-dependencies] | ||
opentelemetry_sdk = { features = ["testing"], path = "../opentelemetry-sdk" } | ||
|
||
[features] | ||
default = [] | ||
integration_test = [] |
Oops, something went wrong.