-
Notifications
You must be signed in to change notification settings - Fork 734
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
tracing-attributes: implement skip_all
#1548
Conversation
Using `#[instrument(skip_all)]` is equivalent to `#[instrument(skip(foo, bar..))]` for all the parameters.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good to me! it might be nice if the test actually called the function with skip_all
, but it's not a hard blocker, since the behavior should be the same as the function with skip
...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
great, thanks for adding the test!
# 0.1.16 (September 13, 2021) This release adds a new `#[instrument(skip_all)]` option to skip recording *all* arguments to an instrumented function as fields. Additionally, it adds support for recording arguments that are `tracing` primitive types as typed values, rather than as `fmt::Debug`. ### Added - add `skip_all` option to `#[instrument]` ([#1548]) - record primitive types as primitive values rather than as `fmt::Debug` ([#1378]) - added support for `f64`s as typed values ([#1522]) Thanks to @Folyd and @jsgf for contributing to this release! [#1548]: #1548 [#1378]: #1378 [#1522]: #1524
# 0.1.16 (September 13, 2021) This release adds a new `#[instrument(skip_all)]` option to skip recording *all* arguments to an instrumented function as fields. Additionally, it adds support for recording arguments that are `tracing` primitive types as typed values, rather than as `fmt::Debug`. ### Added - add `skip_all` option to `#[instrument]` ([#1548]) - record primitive types as primitive values rather than as `fmt::Debug` ([#1378]) - added support for `f64`s as typed values ([#1522]) Thanks to @Folyd and @jsgf for contributing to this release! [#1548]: #1548 [#1378]: #1378 [#1522]: #1524
# 0.1.27 (September 13, 2021) This release adds a new [`Span::or_current`] method to aid in efficiently propagating span contexts to spawned threads or tasks. Additionally, it updates the [`tracing-core`] version to [0.1.20] and the [`tracing-attributes`] version to [0.1.16], ensuring that a number of new features in those crates are present. ### Fixed - **instrument**: Added missing `WithSubscriber` implementations for futures and other types ([#1424]) ### Added - `Span::or_current` method, to help with efficient span context propagation ([#1538]) - **attributes**: add `skip_all` option to `#[instrument]` ([#1548]) - **attributes**: record primitive types as primitive values rather than as `fmt::Debug` ([#1378]) - **core**: `NoSubscriber`, a no-op `Subscriber` implementation ([#1549]) - **core**: Added `Visit::record_f64` and support for recording floating-point values ([#1507], [#1522]) - A large number of documentation improvements and fixes ([#1369], [#1398], [#1435], [#1442], [#1524], [#1556]) Thanks to new contributors @dzvon and @mbergkvist, as well as @teozkr, @maxburke, @LukeMathWalker, and @jsgf, for contributing to this release! [`Span::or_current`]: https://docs.rs/tracing/0.1.27/tracing/struct.Span.html#method.or_current [`tracing-core`]: https://crates.io/crates/tracing-core [`tracing-attributes`]: https://crates.io/crates/tracing-attributes [`tracing-core`]: https://crates.io/crates/tracing-core [0.1.20]: https://github.com/tokio-rs/tracing/releases/tag/tracing-core-0.1.20 [0.1.16]: https://github.com/tokio-rs/tracing/releases/tag/tracing-attributes-0.1.16 [#1424]: #1424 [#1538]: #1538 [#1548]: #1548 [#1378]: #1378 [#1507]: #1507 [#1522]: #1522 [#1369]: #1369 [#1398]: #1398 [#1435]: #1435 [#1442]: #1442
# 0.1.27 (September 13, 2021) This release adds a new [`Span::or_current`] method to aid in efficiently propagating span contexts to spawned threads or tasks. Additionally, it updates the [`tracing-core`] version to [0.1.20] and the [`tracing-attributes`] version to [0.1.16], ensuring that a number of new features in those crates are present. ### Fixed - **instrument**: Added missing `WithSubscriber` implementations for futures and other types (#1424) ### Added - `Span::or_current` method, to help with efficient span context propagation (#1538) - **attributes**: add `skip_all` option to `#[instrument]` (#1548) - **attributes**: record primitive types as primitive values rather than as `fmt::Debug` (#1378) - **core**: `NoSubscriber`, a no-op `Subscriber` implementation (#1549) - **core**: Added `Visit::record_f64` and support for recording floating-point values (#1507, #1522) - A large number of documentation improvements and fixes (#1369, #1398, #1435, #1442, #1524, #1556) Thanks to new contributors @dzvon and @mbergkvist, as well as @teozkr, @maxburke, @LukeMathWalker, and @jsgf, for contributing to this release! [`Span::or_current`]: https://docs.rs/tracing/0.1.27/tracing/struct.Span.html#method.or_current [`tracing-core`]: https://crates.io/crates/tracing-core [`tracing-attributes`]: https://crates.io/crates/tracing-attributes [`tracing-core`]: https://crates.io/crates/tracing-core [0.1.20]: https://github.com/tokio-rs/tracing/releases/tag/tracing-core-0.1.20 [0.1.16]: https://github.com/tokio-rs/tracing/releases/tag/tracing-attributes-0.1.16
Summary: This includes recent changes: - `skip_all` in #[instrument] tokio-rs/tracing#1548 - NoSubscriber no-op Subscriber tokio-rs/tracing#1549 - Box/Arc Layer (tokio-rs/tracing#1536 + tokio-rs/tracing#1547) - log filtering fixes tokio-rs/tracing#1543 Local: force `log` and `log-always` features off. This removes the `enable-trace-logging` flag from smartplatform/reconciler. Reviewed By: guswynn Differential Revision: D30906032 fbshipit-source-id: fdc3e4e29a39e9e181d9f4ff017e6b3e16acdcd8
Summary: This includes recent changes: - `skip_all` in #[instrument] tokio-rs/tracing#1548 - NoSubscriber no-op Subscriber tokio-rs/tracing#1549 - Box/Arc Layer (tokio-rs/tracing#1536 + tokio-rs/tracing#1547) - log filtering fixes tokio-rs/tracing#1543 Local: force `log` and `log-always` features off. This removes the `enable-trace-logging` flag from smartplatform/reconciler. Reviewed By: guswynn Differential Revision: D30906032 fbshipit-source-id: fdc3e4e29a39e9e181d9f4ff017e6b3e16acdcd8
Summary: This includes recent changes: - `skip_all` in #[instrument] tokio-rs/tracing#1548 - NoSubscriber no-op Subscriber tokio-rs/tracing#1549 - Box/Arc Layer (tokio-rs/tracing#1536 + tokio-rs/tracing#1547) - log filtering fixes tokio-rs/tracing#1543 Local: force `log` and `log-always` features off. This removes the `enable-trace-logging` flag from smartplatform/reconciler. Reviewed By: guswynn Differential Revision: D30906032 fbshipit-source-id: fdc3e4e29a39e9e181d9f4ff017e6b3e16acdcd8
Summary: This includes recent changes: - `skip_all` in #[instrument] tokio-rs/tracing#1548 - NoSubscriber no-op Subscriber tokio-rs/tracing#1549 - Box/Arc Layer (tokio-rs/tracing#1536 + tokio-rs/tracing#1547) - log filtering fixes tokio-rs/tracing#1543 Local: force `log` and `log-always` features off. This removes the `enable-trace-logging` flag from smartplatform/reconciler. Reviewed By: guswynn Differential Revision: D30906032 fbshipit-source-id: fdc3e4e29a39e9e181d9f4ff017e6b3e16acdcd8
Summary: This includes recent changes: - `skip_all` in #[instrument] tokio-rs/tracing#1548 - NoSubscriber no-op Subscriber tokio-rs/tracing#1549 - Box/Arc Layer (tokio-rs/tracing#1536 + tokio-rs/tracing#1547) - log filtering fixes tokio-rs/tracing#1543 Local: force `log` and `log-always` features off. This removes the `enable-trace-logging` flag from smartplatform/reconciler. Reviewed By: guswynn Differential Revision: D30906032 fbshipit-source-id: fdc3e4e29a39e9e181d9f4ff017e6b3e16acdcd8
Summary: This includes recent changes: - `skip_all` in #[instrument] tokio-rs/tracing#1548 - NoSubscriber no-op Subscriber tokio-rs/tracing#1549 - Box/Arc Layer (tokio-rs/tracing#1536 + tokio-rs/tracing#1547) - log filtering fixes tokio-rs/tracing#1543 Local: force `log` and `log-always` features off. This removes the `enable-trace-logging` flag from smartplatform/reconciler. Reviewed By: guswynn Differential Revision: D30906032 fbshipit-source-id: fdc3e4e29a39e9e181d9f4ff017e6b3e16acdcd8
Using `#[instrument(skip_all)]` is equivalent to `#[instrument(skip(foo, bar..))]` for all the parameters.
# 0.1.16 (September 13, 2021) This release adds a new `#[instrument(skip_all)]` option to skip recording *all* arguments to an instrumented function as fields. Additionally, it adds support for recording arguments that are `tracing` primitive types as typed values, rather than as `fmt::Debug`. ### Added - add `skip_all` option to `#[instrument]` ([tokio-rs#1548]) - record primitive types as primitive values rather than as `fmt::Debug` ([tokio-rs#1378]) - added support for `f64`s as typed values ([tokio-rs#1522]) Thanks to @Folyd and @jsgf for contributing to this release! [tokio-rs#1548]: tokio-rs#1548 [tokio-rs#1378]: tokio-rs#1378 [tokio-rs#1522]: tokio-rs#1524
# 0.1.27 (September 13, 2021) This release adds a new [`Span::or_current`] method to aid in efficiently propagating span contexts to spawned threads or tasks. Additionally, it updates the [`tracing-core`] version to [0.1.20] and the [`tracing-attributes`] version to [0.1.16], ensuring that a number of new features in those crates are present. ### Fixed - **instrument**: Added missing `WithSubscriber` implementations for futures and other types (tokio-rs#1424) ### Added - `Span::or_current` method, to help with efficient span context propagation (tokio-rs#1538) - **attributes**: add `skip_all` option to `#[instrument]` (tokio-rs#1548) - **attributes**: record primitive types as primitive values rather than as `fmt::Debug` (tokio-rs#1378) - **core**: `NoSubscriber`, a no-op `Subscriber` implementation (tokio-rs#1549) - **core**: Added `Visit::record_f64` and support for recording floating-point values (tokio-rs#1507, tokio-rs#1522) - A large number of documentation improvements and fixes (tokio-rs#1369, tokio-rs#1398, tokio-rs#1435, tokio-rs#1442, tokio-rs#1524, tokio-rs#1556) Thanks to new contributors @dzvon and @mbergkvist, as well as @teozkr, @maxburke, @LukeMathWalker, and @jsgf, for contributing to this release! [`Span::or_current`]: https://docs.rs/tracing/0.1.27/tracing/struct.Span.html#method.or_current [`tracing-core`]: https://crates.io/crates/tracing-core [`tracing-attributes`]: https://crates.io/crates/tracing-attributes [`tracing-core`]: https://crates.io/crates/tracing-core [0.1.20]: https://github.com/tokio-rs/tracing/releases/tag/tracing-core-0.1.20 [0.1.16]: https://github.com/tokio-rs/tracing/releases/tag/tracing-attributes-0.1.16
Using
#[instrument(skip_all)]
is equivalent to#[instrument(skip(foo, bar..))]
for all the parameters.