authgear / authgear-server

Open source alternative to Auth0 / Firebase Auth
https://www.authgear.com
Apache License 2.0
81 stars 37 forks source link

Improve SMTP logging and retry #800

Open louischan-oursky opened 3 years ago

louischan-oursky commented 3 years ago

We are now using https://github.com/go-gomail/gomail to communicate with a remote SMTP server directly. Ben suggested we can have a local SMTP server to handle logs, retry, etc.

chpapa commented 3 years ago

Main thing is for logging and retry which is common to debug in production

kiootic commented 3 years ago

I think the suggest 'SMTP server' is just to have a message queue to handle resiliency. In general, every message sending/batch operations should have this queue (e.g. web-hook events), which is NYI.

chpapa commented 3 years ago

yes it was just my exp the local smtp server handle it too well and easy for debug on production so my rule of thumbs was always have a local smtp server to handle all these.

Technically you can also have a common libraries that do the logging and retry really well and handle every kind of external system calls.