-
Notifications
You must be signed in to change notification settings - Fork 58
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
Standardize logging with tracing
crate + implement micro-benchmarking
#627
Conversation
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.
This just needs a bit of deduplication, back to your queue @winston-h-zhang
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.
So this is starting to look egg-cellent! Thanks for the quick turnaround @winston-h-zhang
A couple of simpler comments inline, all around communicating what's going on, and which I think are needed to complete the "wow" effect of this PR, and then I think we can merge.
@@ -153,7 +155,12 @@ enum Sha256Coproc<F: LurkField> { | |||
/// Run the example in this file with | |||
/// `cargo run --release --example sha256 1 f5a5fd42d16a20302798ef6ed309979b43003d2320d9f0e8ea9831a92759fb4b false` |
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.
Please annotate with the command that would allow printing the TexRay layer to stdout, and recall that command + the output in the PR summary for reviewers to easily get the point of the PR.
tracing
cratetracing
crate + implement micro-benchmarking
- Removed `log` as a workspace dependency and replaced it with `tracing` throughout the project, - Updated clippy linting configuration in `.cargo/config`. - Adapted from `log` crate's `info` module to `tracing` crate's `info` module in `lurk-metrics/src/data.rs`
7ab19fe
to
6c6c1d8
Compare
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.
Tip top, thank you so much @winston-h-zhang !
Resolves #614.
We move away from
log/env_logger/dbg!
and replace everything with the unifiedtracing
ecosystem. All the old logging infrastructure is still there, essentially with a drop in replacement oflog -> tracing
andtracing_subscriber
. Additionally, we add thetracing_texray
crate, with allows us to easily visualize spans and benchmarks of lurk. Texray can be enabled wherever and tracing offers a lot of flexibility; please see the documentation for more info (tracing, tracing-texray)Now running
creates the following pretty output (along with the normal
info
level logs):