docs: the first reconnect delay is 500ms, not ~1s
Caught in review. Cosmetic, but a comment that misstates the constant beside it is the kind of thing the next reader trusts instead of the code.
This commit is contained in:
parent
d56344ea8f
commit
6cbabc3515
1 changed files with 1 additions and 1 deletions
|
|
@ -436,7 +436,7 @@ pub async fn connect(cfg: QueueConfig) -> Result<async_nats::Client, Error> {
|
|||
// See `MAX_RECONNECT_DELAY`. The library's default clamps at 4s forever,
|
||||
// which turns an unreachable queue into a permanent 4s poll — and, before
|
||||
// the cache above, a permanent 4s token-request loop against authelia.
|
||||
// Exponential from ~1s so a momentary blip still reconnects promptly.
|
||||
// Exponential from 500ms so a momentary blip still reconnects promptly.
|
||||
.reconnect_delay_callback(|attempts| {
|
||||
let exp = u32::try_from(attempts.saturating_sub(1)).unwrap_or(u32::MAX);
|
||||
std::cmp::min(
|
||||
|
|
|
|||
Loading…
Reference in a new issue