ops: set an explicit SMTP connect/read timeout instead of trusting lettre defaults #163
Labels
No labels
kind
bug
kind
enhancement
wayfinder
grilling
wayfinder
map
wayfinder
prototype
wayfinder
research
wayfinder
task
workflow
needs-info
workflow
needs-triage
workflow
ready-for-agent
workflow
ready-for-human
workflow
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
rosa/vernier#163
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Found during an operational-resilience review (Release It! stability rules).
Location:
crates/infra/src/jobs/mailer.rs:37Severity: Medium — unbounded wait (Timeouts)
Problem
The lettre SMTP transport is built without an explicit connect/read timeout, so it relies on lettre's / the OS's defaults, which may be effectively unbounded. A hung or half-open SMTP relay can park a mailer worker on a single
sendfor a very long time, consuming worker capacity that healthy mail jobs need.Unlike the webmention client (
webmention.rs), which sets explicit 30s request / 5s connect timeouts, the mail path has no bound the code guarantees.Suggested fix
Set an explicit timeout on the SMTP transport builder so every
sendhas a bounded wait, matching the discipline already applied to the webmention client.