Open mxinden opened 1 month ago
I'd be OK with removing this.
There are some special things neqo_common::log
allows, e.g.,
https://github.com/mozilla/neqo/blob/9f0a86db7f125d731cd10816e57728597d8437b5/neqo-crypto/src/agent.rs#L898-L902
Can we do this with log
?
neqo*
currently usesneqo_common::log
for all things logging. It is a wrapper around thelog
crate.What is the benefit of using
neqo_common::log
over using thelog
crate directly? From what I can tell:neqo_common::log
does not require explicit instantiation of the logger (e.g. viaenv_logger::init
) but instead tries to initialize on each log invocation. https://github.com/mozilla/neqo/blob/c209c439e2aea408594273f6f1c423bbfe723f4f/neqo-common/src/log.rs#L84-L90Are the benefits worth a custom way of logging? Should a library instantiate a logger instead of the conventional instantiation by the calling binary?
Related, other Mozilla code using
log
: https://searchfox.org/mozilla-central/search?q=%5Elog+%3D&path=*Cargo.toml&case=true®exp=true