You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* update to opentelemetry 0.24
* replace `Unit` with the literal directly
* update feature flag
* update import
* update more otel stuff
* use the correct version in readme
* pr review
* update example also to new otel version
* cargo fmt
Copy file name to clipboardexpand all lines: autometrics/build.rs
+4-4
Original file line number
Diff line number
Diff line change
@@ -6,18 +6,18 @@ pub fn main() {
6
6
#[cfg(feature = "metrics")]
7
7
println!("cargo:warning=The `metrics` feature is deprecated and will be removed in the next version. Please use `metrics-0_21` instead.");
8
8
#[cfg(feature = "opentelemetry")]
9
-
println!("cargo:warning=The `opentelemetry` feature is deprecated and will be removed in the next version. Please use `opentelemetry-0_21` instead.");
9
+
println!("cargo:warning=The `opentelemetry` feature is deprecated and will be removed in the next version. Please use `opentelemetry-0_24` instead.");
10
10
#[cfg(feature = "prometheus")]
11
11
println!("cargo:warning=The `prometheus` feature is deprecated and will be removed in the next version. Please use `prometheus-0_13` instead.");
12
12
#[cfg(feature = "prometheus-client")]
13
13
println!("cargo:warning=The `prometheus-client` feature is deprecated and will be removed in the next version. Please use `prometheus-client-0_22` instead.");
println!("cargo:warning=The `exemplars-tracing-opentelemetry` feature is deprecated and will be removed in the next version. Please use `exemplars-tracing-opentelemetry-0_22` instead.");
15
+
println!("cargo:warning=The `exemplars-tracing-opentelemetry` feature is deprecated and will be removed in the next version. Please use `exemplars-tracing-opentelemetry-0_25` instead.");
Copy file name to clipboardexpand all lines: autometrics/src/README.md
+2-2
Original file line number
Diff line number
Diff line change
@@ -153,7 +153,7 @@ If you require more customization than these offered feature flags, enable just
153
153
154
154
> If you are exporting metrics yourself rather than using the `prometheus-exporter`, you must ensure that you are using the exact same version of the metrics library as `autometrics` (and it must come from `crates.io` rather than git or another source). If not, the autometrics metrics will not appear in your exported metrics.
155
155
156
-
-`opentelemetry-0_21` - use the [opentelemetry](https://crates.io/crates/opentelemetry) crate for producing metrics.
156
+
-`opentelemetry-0_24` - use the [opentelemetry](https://crates.io/crates/opentelemetry) crate for producing metrics.
157
157
-`metrics-0_21` - use the [metrics](https://crates.io/crates/metrics) crate for producing metrics
158
158
-`prometheus-0_13` - use the [prometheus](https://crates.io/crates/prometheus) crate for producing metrics
159
159
-`prometheus-client-0_22` - use the official [prometheus-client](https://crates.io/crates/prometheus-client) crate for producing metrics
@@ -163,7 +163,7 @@ If you require more customization than these offered feature flags, enable just
163
163
See the [exemplars module docs](https://docs.rs/autometrics/latest/autometrics/exemplars/index.html) for details about these features. Currently only supported with the `prometheus-client` backend.
164
164
165
165
-`exemplars-tracing` - extract arbitrary fields from `tracing::Span`s
166
-
-`exemplars-tracing-opentelemetry-0_20` or `exemplars-tracing-opentelemetry-0_21` - extract the `trace_id` and `span_id` from the `opentelemetry::Context`, which is attached to `tracing::Span`s by the `tracing-opentelemetry` crate
166
+
-`exemplars-tracing-opentelemetry-0_25` - extract the `trace_id` and `span_id` from the `opentelemetry::Context`, which is attached to `tracing::Span`s by the `tracing-opentelemetry` crate
Copy file name to clipboardexpand all lines: autometrics/src/otel_push_exporter.rs
+4-4
Original file line number
Diff line number
Diff line change
@@ -1,17 +1,17 @@
1
1
use opentelemetry::metrics::MetricsError;
2
2
use opentelemetry_otlp::{ExportConfig,Protocol,WithExportConfig};
3
3
use opentelemetry_otlp::{OtlpMetricPipeline,OTEL_EXPORTER_OTLP_TIMEOUT_DEFAULT};
4
-
use opentelemetry_sdk::metrics::MeterProvider;
4
+
use opentelemetry_sdk::metrics::SdkMeterProvider;
5
5
use std::ops::Deref;
6
6
use std::time::Duration;
7
7
8
-
/// Newtype struct holding a [`MeterProvider`] with a custom `Drop` implementation to automatically clean up itself
8
+
/// Newtype struct holding a [`SdkMeterProvider`] with a custom `Drop` implementation to automatically clean up itself
9
9
#[repr(transparent)]
10
10
#[must_use = "Assign this to a unused variable instead: `let _meter = ...` (NOT `let _ = ...`), as else it will be dropped immediately - which will cause it to be shut down"]
0 commit comments