mirror of
https://github.com/rwf2/Rocket.git
synced 2025-02-02 06:42:03 +00:00
926e06ef3c
This commit complete the migration to 'tracing' for all logging. Below is a summary of all relevant commits, including this one: Log improvements: - All log (trace) messages are structured which means they contain fields that can formatted by any subscriber. - Logging can be disabled entirely by disabling the default `trace` feature. - Routes and catchers now contain location (file/line) information. - Two log format kinds: pretty and compact via ROCKET_LOG_FORMAT - Coloring is not disabled globally. Thus applications can color even if Rocket is configured not to. - Rocket is more conservative about 'warn' and 'error' messages, reserving those log levels for messages useful in production. - Errors from guards logged by codegen now use the 'Display' implementation of those errors when one exists. - Secrets are never logged, even when directly asked for. New features: - Many Rocket types know how to trace themselves via a new `Trace` trait. - `Either` types can now be used in `uri!()` calls. - A `RequestIdLayer` tags all requests with a unique ID. Breaking changes to configuration: - `Config::log_level` is of type `Option<Level>`. `None` disables tracing. - `log_level` now uses the traditional log level names: "off", "error", "warn", "info", "debug", "trace", or 0-5. This replace the Rocket-specific "normal", "debug", "critical". - A new option, `log_format`, which is either `compact` or `pretty`, determines how Rocket's tracing subscriber log trace messages. Breaking changes: - Hidden `rocket::Either` is now publicly available at `rocket::either::Either`. - `rocket::Error` no longer panics when dropped. - `main` generated by `#[launch]` returns an `ExitCode`. - `FromParam` `Err` now always returns the actual error as opposed to the string that failed to parse. To recover the original string, use `Either<T, &str>`, where `T: FromParam`, as a parameter guard. - Many types that implemented `Display` now instead implement `Trace`. - `Error::pretty_print()` was removed. Use `Error::trace()` via `Trace` impl. Internal improvements: - Made more space in CI machines for tasks. - Cleaned up testbench code using `inventory`. Resolves #21. |
||
---|---|---|
.. | ||
static | ||
absolute-uris-okay-issue-443.rs | ||
adhoc-uri-normalizer.rs | ||
byte-slices-form-field-issue-2148.rs | ||
can-correct-bad-local-uri.rs | ||
can-launch-tls.rs | ||
catcher-cookies-1213.rs | ||
conditionally-set-server-header-996.rs | ||
config-proxy-proto-header.rs | ||
config-real-ip-header.rs | ||
config-secret-key-1500.rs | ||
content-length.rs | ||
cookies-private.rs | ||
derive-reexports.rs | ||
deserialize-limits-issue-2268.rs | ||
encoded-uris.rs | ||
fairing_before_head_strip-issue-546.rs | ||
file_server.rs | ||
flash-lazy-removes-issue-466.rs | ||
form_method-issue-45.rs | ||
form_value_decoding-issue-82.rs | ||
form_value_from_encoded_str-issue-1425.rs | ||
form-validation-names.rs | ||
forward-includes-status-1560.rs | ||
head_handling.rs | ||
http_serde.rs | ||
launch-inspect.rs | ||
limits.rs | ||
local_request_private_cookie-issue-368.rs | ||
local-client-access-runtime-in-drop.rs | ||
local-client-json.rs | ||
local-request-content-type-issue-505.rs | ||
many-cookie-jars-at-once.rs | ||
mapped-base-issue-1262.rs | ||
mount_point.rs | ||
multipart-limit.rs | ||
nested-fairing-attaches.rs | ||
on_launch_fairing_can_inspect_port.rs | ||
panic-handling.rs | ||
precise-content-type-matching.rs | ||
raw-strings-multipart-files-1987.rs | ||
recursive-singleton-fairing.rs | ||
redirect_from_catcher-issue-113.rs | ||
replace-content-type-518.rs | ||
responder_lifetime-issue-345.rs | ||
route_guard.rs | ||
scoped-uri.rs | ||
segments-issues-41-86.rs | ||
sentinel.rs | ||
session-cookies-issue-1506.rs | ||
shield.rs | ||
shutdown-fairings.rs | ||
strict_and_lenient_forms.rs | ||
timer-on-attach.rs | ||
tls-config-from-source-1503.rs | ||
twice_managed_state.rs | ||
typed-uri-docs-redef-issue-1373.rs | ||
unsound-local-request-1312.rs | ||
untracked-vs-tracked.rs | ||
uri-percent-encoding-issue-808.rs |