diff --git a/apps/api/src/dkv/dkv-mail.service.ts b/apps/api/src/dkv/dkv-mail.service.ts index 60c28fe..de276b5 100644 --- a/apps/api/src/dkv/dkv-mail.service.ts +++ b/apps/api/src/dkv/dkv-mail.service.ts @@ -103,6 +103,11 @@ export class DkvMailService { ); // RETHROW — caller (DkvService) handles exponential backoff retries (D-16) throw error; + } finally { + // Always close the transport to release the SMTP connection pool (WR-01). + // Without this, repeated sends (especially with retry backoff) accumulate + // open connections and can exhaust OS socket limits. + transport.close(); } } }