rust-lang / log

Logging implementation for Rust
https://docs.rs/log
Apache License 2.0
2.16k stars 250 forks source link

Review of key-value feature #584

Closed Thomasdezeeuw closed 6 months ago

Thomasdezeeuw commented 1 year ago

Discussion for https://github.com/rust-lang/log/issues/328.

KodrAus commented 10 months ago

Thanks for all the time you've spent digging through this so far @Thomasdezeeuw! I think we're getting towards something that feels appropriate for the log crate without losing capability.

KodrAus commented 8 months ago

Just checking back in on this, is the main blocker we've got deciding whether to default to capturing using ToValue and supporting some tracing-like syntax for changing it?

Thomasdezeeuw commented 8 months ago

Just checking back in on this, is the main blocker we've got deciding whether to default to capturing using ToValue and supporting some tracing-like syntax for changing it?

Yes, I think those are the two main things from this pr.

KodrAus commented 7 months ago

I'm doing some work on this now; removing the Value::capture_* and downcasting methods, and improving the overall documentation for the kv module.

It looks like we already default to using ToValue for key-values, so nothing needs to change there. That just leaves some nicer macro support for tweaking how values are captured.

Are you happy with that plan @Thomasdezeeuw?

KodrAus commented 7 months ago

I've opened #613 for this. I'll cc there once it's ready for review, but wanted to point it out here too.

Thomasdezeeuw commented 7 months ago

Are you happy with that plan @Thomasdezeeuw?

Yes, sounds good :+1: