diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ed7ed11..2abfe0c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,7 +16,7 @@ jobs: fail-fast: false matrix: os: [ windows-latest, macos-latest, ubuntu-latest ] - rust: [ "1.80.1", stable, nightly ] + rust: [ "1.75", stable, nightly ] env: RUST_BACKTRACE: 1 steps: diff --git a/CHANGELOG.md b/CHANGELOG.md index 7285565..4888c0b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,10 @@ ## Unreleased +## v0.7.1 + +- Lower MSRV to 1.75. + ## v0.7.0 - Upgrade dependencies including opentelemtry and more. diff --git a/Cargo.toml b/Cargo.toml index 4c6a4b6..e6f1e9a 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -14,12 +14,12 @@ resolver = "2" edition = "2021" license = "Apache-2.0" repository = "https://github.com/fast/fastrace" -rust-version = "1.80.1" +rust-version = "1.75" [workspace.dependencies] # workspace dependencies -fastrace = { version = "0.7.0", path = "fastrace" } -fastrace-macro = { version = "0.7.0", path = "fastrace-macro" } +fastrace = { version = "0.7.1", path = "fastrace" } +fastrace-macro = { version = "0.7.1", path = "fastrace-macro" } # workspace leaves fastrace-datadog = { path = "fastrace-datadog" } diff --git a/README.md b/README.md index cecebc0..b20f15f 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ [![Crates.io](https://img.shields.io/crates/v/fastrace.svg?style=flat-square&logo=rust)](https://crates.io/crates/fastrace) [![Documentation](https://img.shields.io/docsrs/fastrace?style=flat-square&logo=rust)](https://docs.rs/fastrace/) -[![MSRV 1.80.1](https://img.shields.io/badge/MSRV-1.80.1-green?style=flat-square&logo=rust)](https://www.whatrustisit.com) +[![MSRV 1.75.0](https://img.shields.io/badge/MSRV-1.75.0-green?style=flat-square&logo=rust)](https://www.whatrustisit.com) [![CI Status](https://img.shields.io/github/actions/workflow/status/fast/fastrace/ci.yml?style=flat-square&logo=github)](https://github.com/fast/fastrace/actions) [![License](https://img.shields.io/crates/l/fastrace?style=flat-square)](https://github.com/fast/fastrace/blob/main/LICENSE) @@ -113,9 +113,9 @@ fn main() { Detailed results are available in [etc/benchmark-result](etc/benchmark-result). -## Supported Rust Versions (MSRV 1.80.1) +## Supported Rust Versions (MSRV 1.75.0) -Fastrace is built against the latest stable release. The minimum supported version is 1.80.1. The current Fastrace version is not guaranteed to build on Rust versions earlier than the minimum supported version. +Fastrace is built against the latest stable release. The minimum supported version is 1.75.0. The current Fastrace version is not guaranteed to build on Rust versions earlier than the minimum supported version. ## Projects using fastrace diff --git a/fastrace-datadog/Cargo.toml b/fastrace-datadog/Cargo.toml index 1ccae11..0470e6d 100644 --- a/fastrace-datadog/Cargo.toml +++ b/fastrace-datadog/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "fastrace-datadog" -version = "0.7.0" +version = "0.7.1" categories = ["development-tools::debugging"] description = "Datadog reporter for fastrace" diff --git a/fastrace-futures/Cargo.toml b/fastrace-futures/Cargo.toml index ad134ae..08e0f84 100644 --- a/fastrace-futures/Cargo.toml +++ b/fastrace-futures/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "fastrace-futures" -version = "0.7.0" +version = "0.7.1" categories = ["development-tools::debugging"] description = "Utilities for tracing `futures` with fastrace" diff --git a/fastrace-jaeger/Cargo.toml b/fastrace-jaeger/Cargo.toml index ed0c275..def651d 100644 --- a/fastrace-jaeger/Cargo.toml +++ b/fastrace-jaeger/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "fastrace-jaeger" -version = "0.7.0" +version = "0.7.1" categories = ["development-tools::debugging"] description = "Jaeger reporter for fastrace" diff --git a/fastrace-macro/Cargo.toml b/fastrace-macro/Cargo.toml index 07d74e6..bd6c5a9 100644 --- a/fastrace-macro/Cargo.toml +++ b/fastrace-macro/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "fastrace-macro" -version = "0.7.0" +version = "0.7.1" categories = ["development-tools::debugging"] description = "Attribute procedural macro for fastrace" diff --git a/fastrace-opentelemetry/Cargo.toml b/fastrace-opentelemetry/Cargo.toml index 4a8039e..a5af256 100644 --- a/fastrace-opentelemetry/Cargo.toml +++ b/fastrace-opentelemetry/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "fastrace-opentelemetry" -version = "0.7.0" +version = "0.7.1" categories = ["development-tools::debugging"] description = "Opentelemetry reporter for fastrace" diff --git a/fastrace/Cargo.toml b/fastrace/Cargo.toml index e852791..6745eb8 100644 --- a/fastrace/Cargo.toml +++ b/fastrace/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "fastrace" -version = "0.7.0" +version = "0.7.1" categories = ["development-tools::debugging"] description = "A high-performance timeline tracing library for Rust" @@ -24,6 +24,9 @@ pin-project = "1.1" rand = "0.8" rtrb = "0.3" +# TODO: remove once_cell once MSRV is above 1.80 +once_cell = "1.19" + [dev-dependencies] async-trait = "0.1" criterion = { version = "0.5", features = ["html_reports"] } diff --git a/fastrace/src/macros.rs b/fastrace/src/macros.rs index fc2d53d..54a223c 100644 --- a/fastrace/src/macros.rs +++ b/fastrace/src/macros.rs @@ -52,7 +52,7 @@ macro_rules! func_path { } /// Get the full path of the function where the macro is invoked. Returns a `&'static str`. -#[deprecated(since = "0.7.0", note = "Please use `fastrace::func_path!()` instead")] +#[deprecated(since = "0.7.1", note = "Please use `fastrace::func_path!()` instead")] #[macro_export] macro_rules! full_name { () => {{ diff --git a/fastrace/src/util/mod.rs b/fastrace/src/util/mod.rs index 6d77d8f..4ae9fa3 100644 --- a/fastrace/src/util/mod.rs +++ b/fastrace/src/util/mod.rs @@ -8,7 +8,8 @@ pub mod tree; use std::borrow::Cow; use std::cell::RefCell; -use std::sync::LazyLock; + +use once_cell::sync::Lazy; use crate::collector::CollectTokenItem; use crate::local::raw_span::RawSpan; @@ -16,13 +17,12 @@ use crate::util::object_pool::Pool; use crate::util::object_pool::Puller; use crate::util::object_pool::Reusable; -static RAW_SPANS_POOL: LazyLock>> = - LazyLock::new(|| Pool::new(Vec::new, Vec::clear)); -static COLLECT_TOKEN_ITEMS_POOL: LazyLock>> = - LazyLock::new(|| Pool::new(Vec::new, Vec::clear)); +static RAW_SPANS_POOL: Lazy>> = Lazy::new(|| Pool::new(Vec::new, Vec::clear)); +static COLLECT_TOKEN_ITEMS_POOL: Lazy>> = + Lazy::new(|| Pool::new(Vec::new, Vec::clear)); #[allow(clippy::type_complexity)] -static PROPERTIES_POOL: LazyLock, Cow<'static, str>)>>> = - LazyLock::new(|| Pool::new(Vec::new, Vec::clear)); +static PROPERTIES_POOL: Lazy, Cow<'static, str>)>>> = + Lazy::new(|| Pool::new(Vec::new, Vec::clear)); thread_local! { static RAW_SPANS_PULLER: RefCell>> = RefCell::new(RAW_SPANS_POOL.puller(512));