From 14147286ba61bc94d5b100791ddf4b2b37fd7c13 Mon Sep 17 00:00:00 2001 From: Riley Date: Mon, 13 Dec 2021 09:45:34 -0600 Subject: [PATCH] Update to actix-web beta.14 (#61) * Update to actix-web beta.14 * Fix HeaderMap import --- Cargo.toml | 2 +- examples/custom-root-span/Cargo.toml | 2 +- examples/opentelemetry/Cargo.toml | 2 +- src/otel.rs | 4 ++-- src/request_id.rs | 2 +- src/root_span.rs | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index f298bf9fb..f031a97a6 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -27,7 +27,7 @@ opentelemetry_0_16 = ["opentelemetry_0_16_pkg", "tracing-opentelemetry_0_16_pkg" emit_event_on_error = [] [dependencies] -actix-web = { version = "=4.0.0-beta.13", default-features = false } +actix-web = { version = "=4.0.0-beta.14", default-features = false } pin-project = "1.0.0" tracing = "0.1.19" tracing-futures = "0.2.4" diff --git a/examples/custom-root-span/Cargo.toml b/examples/custom-root-span/Cargo.toml index 17a352ab5..94ae5f056 100644 --- a/examples/custom-root-span/Cargo.toml +++ b/examples/custom-root-span/Cargo.toml @@ -7,7 +7,7 @@ edition = "2018" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] -actix-web = "=4.0.0-beta.13" +actix-web = "=4.0.0-beta.14" opentelemetry = { version = "0.16", features = ["rt-tokio-current-thread"] } opentelemetry-jaeger = { version = "0.15", features = ["rt-tokio-current-thread"] } tracing-opentelemetry = { version = "0.16" } diff --git a/examples/opentelemetry/Cargo.toml b/examples/opentelemetry/Cargo.toml index 1ef730738..0a20b99cb 100644 --- a/examples/opentelemetry/Cargo.toml +++ b/examples/opentelemetry/Cargo.toml @@ -7,7 +7,7 @@ edition = "2018" license = "MIT/Apache-2.0" [dependencies] -actix-web = "=4.0.0-beta.13" +actix-web = "=4.0.0-beta.14" tracing = "0.1.19" opentelemetry = { version = "0.16", features = ["rt-tokio-current-thread"] } opentelemetry-jaeger = { version = "0.15", features = ["rt-tokio-current-thread"] } diff --git a/src/otel.rs b/src/otel.rs index fd4df5e91..85b795caa 100644 --- a/src/otel.rs +++ b/src/otel.rs @@ -21,11 +21,11 @@ use tracing_opentelemetry_0_16_pkg as tracing_opentelemetry; use opentelemetry::propagation::Extractor; pub(crate) struct RequestHeaderCarrier<'a> { - headers: &'a actix_web::http::HeaderMap, + headers: &'a actix_web::http::header::HeaderMap, } impl<'a> RequestHeaderCarrier<'a> { - pub(crate) fn new(headers: &'a actix_web::http::HeaderMap) -> Self { + pub(crate) fn new(headers: &'a actix_web::http::header::HeaderMap) -> Self { RequestHeaderCarrier { headers } } } diff --git a/src/request_id.rs b/src/request_id.rs index 969827a06..3a20dbba0 100644 --- a/src/request_id.rs +++ b/src/request_id.rs @@ -1,4 +1,4 @@ -use actix_web::dev::Payload; +use actix_web::{dev::Payload, HttpMessage}; use actix_web::{FromRequest, HttpRequest, ResponseError}; use std::future::{ready, Ready}; use uuid::Uuid; diff --git a/src/root_span.rs b/src/root_span.rs index 11d173a4b..624a44212 100644 --- a/src/root_span.rs +++ b/src/root_span.rs @@ -1,4 +1,4 @@ -use actix_web::dev::Payload; +use actix_web::{dev::Payload, HttpMessage}; use actix_web::{FromRequest, HttpRequest, ResponseError}; use std::future::{ready, Ready}; use tracing::Span;