jmgilman / vaultrs

An asynchronous Rust client library for the Hashicorp Vault API
https://docs.rs/vaultrs
MIT License
97 stars 60 forks source link

Improve logging #87

Closed stormshield-gt closed 3 months ago

stormshield-gt commented 6 months ago

Attempt to address some of the concerns raised in https://github.com/jmgilman/vaultrs/issues/86

Here there is an example to the new log, which can be useful to compare with the one in https://github.com/jmgilman/vaultrs/pull/85 . Here, RUST_LOG="info,rustify=off" is used, as it won't likely to be fixed upstream.

Unhappy path:

2024-03-27T08:06:02.413716Z  INFO request{method=GET path=/sys/health}: vaultrs::api: start request
2024-03-27T08:06:02.422478Z ERROR request{method=GET path=/sys/health}: vaultrs::api: error=An error occurred with the request

Happy path:

2024-03-27T08:06:00.283379Z  INFO request{method=POST path=/sys/init}: vaultrs::api: start request
Haennetz commented 4 months ago

Can you please rebase your branch witch main to resolve the conflict?

stormshield-gt commented 4 months ago

This should be fine now

Haennetz commented 3 months ago

Nice work.