From 9fc00f25be56df0147c259da65a1f552750d1d82 Mon Sep 17 00:00:00 2001 From: mcc Date: Fri, 14 Aug 2026 14:09:05 -0400 Subject: [PATCH] Correct docs to reflect log_level names in post-tracing Rocket Specifically, off/critical/normal/debug are now off/error/warn/info/debug/trace, and the defaults are now info/error instead of normal/critical. --- docs/guide/03-getting-started.md | 2 +- docs/guide/04-overview.md | 2 +- docs/guide/10-configuration.md | 40 ++++++++++++++++---------------- docs/guide/11-deploying.md | 4 ++-- 4 files changed, 24 insertions(+), 24 deletions(-) diff --git a/docs/guide/03-getting-started.md b/docs/guide/03-getting-started.md index 5d40838105..2ab352f0c7 100644 --- a/docs/guide/03-getting-started.md +++ b/docs/guide/03-getting-started.md @@ -92,7 +92,7 @@ run`. You should see the following: >> limits: [..] >> tls: disabled >> temp dir: /tmp - >> log level: normal + >> log level: info >> cli colors: true 🛰 Routes: >> (index) GET / diff --git a/docs/guide/04-overview.md b/docs/guide/04-overview.md index b0fce4d1ec..f922d486de 100644 --- a/docs/guide/04-overview.md +++ b/docs/guide/04-overview.md @@ -176,7 +176,7 @@ Running the application, the console shows: >> limits: [..] >> tls: disabled >> temp dir: /tmp - >> log level: normal + >> log level: info >> cli colors: true 🛰 Routes: >> (world) GET /hello/world diff --git a/docs/guide/10-configuration.md b/docs/guide/10-configuration.md index ffe018eac5..d21ea425ae 100644 --- a/docs/guide/10-configuration.md +++ b/docs/guide/10-configuration.md @@ -21,24 +21,24 @@ is configured with. This means that no matter which configuration provider Rocket is asked to use, it must be able to read the following configuration values: -| key | kind | description | debug/release default | -|----------------------|--------------------|-------------------------------------------------|-------------------------------| -| `address` | `IpAddr` | IP address to serve on. | `127.0.0.1` | -| `port` | `u16` | Port to serve on. | `8000` | -| `workers`* | `usize` | Number of threads to use for executing futures. | cpu core count | -| `max_blocking`* | `usize` | Limit on threads to start for blocking tasks. | `512` | -| `ident` | `string`, `false` | If and how to identify via the `Server` header. | `"Rocket"` | -| `ip_header` | `string`, `false` | IP header to inspect to get [client's real IP]. | `"X-Real-IP"` | -| `proxy_proto_header` | `string`, `false` | Header identifying [client to proxy protocol]. | `None` | -| `keep_alive` | `u32` | Keep-alive timeout seconds; disabled when `0`. | `5` | -| `log_level` | [`LogLevel`] | Max level to log. (off/normal/debug/critical) | `normal`/`critical` | -| `cli_colors` | [`CliColors`] | Whether to use colors and emoji when logging. | `"auto"` | -| `secret_key` | [`SecretKey`] | Secret key for signing and encrypting values. | `None` | -| `tls` | [`TlsConfig`] | TLS configuration, if any. | `None` | -| `limits` | [`Limits`] | Streaming read size limits. | [`Limits::default()`] | -| `limits.$name` | `&str`/`uint` | Read limit for `$name`. | form = "32KiB" | -| `ctrlc` | `bool` | Whether `ctrl-c` initiates a server shutdown. | `true` | -| `shutdown`* | [`ShutdownConfig`] | Graceful shutdown configuration. | [`ShutdownConfig::default()`] | +| key | kind | description | debug/release default | +|----------------------|--------------------|-------------------------------------------------------|-------------------------------| +| `address` | `IpAddr` | IP address to serve on. | `127.0.0.1` | +| `port` | `u16` | Port to serve on. | `8000` | +| `workers`* | `usize` | Number of threads to use for executing futures. | cpu core count | +| `max_blocking`* | `usize` | Limit on threads to start for blocking tasks. | `512` | +| `ident` | `string`, `false` | If and how to identify via the `Server` header. | `"Rocket"` | +| `ip_header` | `string`, `false` | IP header to inspect to get [client's real IP]. | `"X-Real-IP"` | +| `proxy_proto_header` | `string`, `false` | Header identifying [client to proxy protocol]. | `None` | +| `keep_alive` | `u32` | Keep-alive timeout seconds; disabled when `0`. | `5` | +| `log_level` | [`LogLevel`] | Max level to log. (off/error/warn/info/debug/trace) | `info`/`error` | +| `cli_colors` | [`CliColors`] | Whether to use colors and emoji when logging. | `"auto"` | +| `secret_key` | [`SecretKey`] | Secret key for signing and encrypting values. | `None` | +| `tls` | [`TlsConfig`] | TLS configuration, if any. | `None` | +| `limits` | [`Limits`] | Streaming read size limits. | [`Limits::default()`] | +| `limits.$name` | `&str`/`uint` | Read limit for `$name`. | form = "32KiB" | +| `ctrlc` | `bool` | Whether `ctrl-c` initiates a server shutdown. | `true` | +| `shutdown`* | [`ShutdownConfig`] | Graceful shutdown configuration. | [`ShutdownConfig::default()`] | * Note: the `workers`, `max_blocking`, and `shutdown.force` configuration @@ -95,7 +95,7 @@ sources in ascending priority order: The selected profile is the value of the `ROCKET_PROFILE` environment variable, or if it is not set, "debug" when compiled in debug mode and "release" when compiled in release mode. With the exception of `log_level`, which changes from -`normal` in debug to `critical` in release, all of the default configuration +`info` in debug to `error` in release, all of the default configuration values are the same in all profiles. What's more, all configuration values _have_ defaults, so no configuration is needed to get started. @@ -158,7 +158,7 @@ keep_alive = 5 ident = "Rocket" ip_header = "X-Real-IP" # set to `false` to disable proxy_proto_header = false # set to `false` (the default) to disable -log_level = "normal" +log_level = "info" temp_dir = "/tmp" cli_colors = true # NOTE: Don't (!) use this key! Generate your own and keep it private! diff --git a/docs/guide/11-deploying.md b/docs/guide/11-deploying.md index 8bdd4f8ade..bc1d2696ee 100644 --- a/docs/guide/11-deploying.md +++ b/docs/guide/11-deploying.md @@ -323,8 +323,8 @@ environment, we provide only the following general guidelines: * **Enable debug logging if the application misbehaves.** - The default log level in `--release` (the release profile) is `critical`. + The default log level in `--release` (the release profile) is `error`. This level may omit messages helpful in understanding application - misbehavior. To reenable those messages, set `ROCKET_LOG_LEVEL=debug`. + misbehavior. To enable all messages, set `ROCKET_LOG_LEVEL=debug`. [configuration profile]: ../configuration/#profiles