Track email queue ID

(Michael Brown) #1

For any email we deliver (Admin / Email / Sent) we should log the queue ID. For example:

250 2.0.0 OK 1398407462 tv5si4104952pbc.459 - gsmtp

This would make it possible to track down sent email if there’s a problem.

(Kevin P. Fleming) #2

That would require parsing logic for every SMTP server that Discourse could talk to, and assume that the server is not running a modified version of whatever MTA it uses. The content of the ‘250’ message is not specified by any standard, beyond the ‘2.0.0’ enhanced status code.

(Michael Brown) #3

No, it’s sufficient (and desirable) to log the entire 250 response, just like an MTA would.

(Kevin P. Fleming) #4

Oh, right, you said ‘log the queue ID’, so I thought you mean ‘extract the queue ID from the response’ :smile: