Skip to content
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

core: tracking issue for tracing-core 0.2 breaking changes #922

Open
5 of 13 tasks
hawkw opened this issue Aug 13, 2020 · 6 comments
Open
5 of 13 tasks

core: tracking issue for tracing-core 0.2 breaking changes #922

hawkw opened this issue Aug 13, 2020 · 6 comments
Assignees
Labels
crate/core Related to the `tracing-core` crate meta/breaking This is a breaking change, and should wait until the next breaking release.

Comments

@hawkw
Copy link
Member

hawkw commented Aug 13, 2020

Feature Request

Crates

  • tracing-core

Motivation

In order to reduce churn throughout the ecosystem, we intend to synchronize the tokio 0.3 and tracing-core 0.2 releases. This issue will track and discuss tracing-core 0.2 breaking changes.

Note that some of the listed changes involve phrasing like "Consider doing X". In those cases, the benefits and drawbacks of those changes need to be investigated further before we commit to making them in 0.2.

Minor API Tweaks

These are low-hanging fruit API changes that don't require a great deal of work, but can't be changed without breaking existing APIs.

Metadata/Callsite improvements

  • Investigate removing cyclic Metadata <-> Callsite reference (needs issue)
  • Consider using Cow<str, 'static> for Metadata strings rather than &'static str (needs issue)
  • Consider introducing statically discoverable metadata (core: introduce statically discoverable metadata #969)

Value System Improvements

See RFC for ValueSet ergonomics improvements #697.

@hawkw hawkw added crate/core Related to the `tracing-core` crate meta/breaking This is a breaking change, and should wait until the next breaking release. labels Aug 13, 2020
@hawkw hawkw added this to the tracing-core 0.2 milestone Aug 13, 2020
@hawkw hawkw self-assigned this Aug 13, 2020
@hawkw hawkw pinned this issue Aug 13, 2020
@hawkw
Copy link
Member Author

hawkw commented Aug 13, 2020

There are also a handful of proposed changes which don't appear to inherently require breaking API changes, but may not be possible to implement without breaking changes (or could be implemented more easily with breaking changes). It would be worth doing further investigation of those proposed changes while we have the opportunity to break things for 0.2.

These include:

@hawkw
Copy link
Member Author

hawkw commented Aug 13, 2020

There are probably other issues and proposed changes I've missed, both on the lists of definite breaking changes, and on the list of proposed changes that should be investigated prior to shipping a breaking release. If anyone can think of anything I've left out, please post them here!

dvdplm added a commit to dvdplm/tracing that referenced this issue Oct 16, 2020
This changes `set_global_default` to take a reference to its `Dispatch` for a more consistent API at the cost of a one-time clone when initializing the `GLOBAL_DISPATCH` static.

Closes tokio-rs#455
Part of tokio-rs#922
dvdplm added a commit to dvdplm/tracing that referenced this issue Oct 19, 2020
As an alternative to tokio-rs#1045, this PR switches `set_default` and `with_default` to take an owned `Dispatch` instead of a ref.

See [comment here](tokio-rs#1045 (comment)) for motivation.

Closes tokio-rs#455
Part of tokio-rs#922
@hawkw
Copy link
Member Author

hawkw commented Feb 23, 2021

Opened #1262 for removing some default method impls from Collect that were initially added for backwards compatibility when adding new methods.

@carllerche
Copy link
Member

I believe there was some discussion about changing the Subscriber/Collector trait to enable avoiding map lookups when handling events. Is that reflected yet? If not, I am leaving the comment so we don't forget 😄 .

@hawkw
Copy link
Member Author

hawkw commented Feb 23, 2021

I believe there was some discussion about changing the Subscriber/Collector trait to enable avoiding map lookups when handling events. Is that reflected yet? If not, I am leaving the comment so we don't forget smile .

There isn't an issue for that yet --- I thought you said you were going to write a proposal for it, but I may have misremembered that. I can try to write one if you'd prefer?

@carllerche
Copy link
Member

I can write a proposal, but we should have a placeholder issue until then :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
crate/core Related to the `tracing-core` crate meta/breaking This is a breaking change, and should wait until the next breaking release.
Projects
None yet
Development

No branches or pull requests

4 participants