feat(mail/delivery): add error-count based blocking to rate limiter; improve test SMTP server port selection; add tsbuild scripts and devDependency; remove stale backup file

This commit is contained in:
2026-02-10 14:44:45 +00:00
parent f262f602a0
commit 14be3cdb9a
8 changed files with 9718 additions and 709 deletions

View File

@@ -185,12 +185,12 @@ export class SmtpServer implements ISmtpServer {
reject(new Error('Server not initialized'));
return;
}
this.server.listen(this.options.port, this.options.host, () => {
SmtpLogger.info(`SMTP server listening on ${this.options.host || '0.0.0.0'}:${this.options.port}`);
resolve();
});
this.server.on('error', reject);
});
@@ -458,7 +458,7 @@ export class SmtpServer implements ISmtpServer {
public getEmailServer(): UnifiedEmailServer {
return this.emailServer;
}
/**
* Check if the server is running
* @returns Whether the server is running