parsimony/internal/outbound
Repository files (latest commit first)
Filename Latest commit message Latest commit date
tgiachi f14faf52d5 fix(outbound): give each SMTP phase its own deadline
A relay can take minutes to answer the final dot (content filter,
large message, slow link). One deadline over the whole transaction
cut it after the message had been accepted, so the delivery was
retried and sent again.

The connection now moves its deadline as the transaction advances:
setup (dial, greeting, TLS, AUTH, MAIL, RCPT, DATA) has
SMTPRelay.Timeout, 60 s by default; the upload has 60 s plus the size
at 32 KiB/s, at most 10 minutes; the reply to the final dot has
10 minutes (RFC 5321 4.5.3.2.6). go-smtp sets and clears its own
per-command deadlines, so a wrapper clips them to the current phase.
Context cancellation still closes the connection at once. A timeout
in any phase is temporary; after the final dot the error says the
outcome is unknown.
2026-11-10 15:20:49 +01:00
..
outbound.go fix(outbound): give each SMTP phase its own deadline 2026-11-10 15:20:49 +01:00
outbound_test.go test: pin the SMTP command named in a relay error, SMTPUTF8 and thread order 2026-11-10 11:42:19 +01:00
timeout_test.go fix(outbound): give each SMTP phase its own deadline 2026-11-10 15:20:49 +01:00
tls_test.go test: pin the relay settings that reach the SMTP client 2026-11-10 11:11:50 +01:00