more perf tweaks.

This commit is contained in:
2022-04-09 10:58:10 -07:00
parent cd7c17794e
commit cbc3c00b8e
3 changed files with 55 additions and 16 deletions

View File

@@ -23,8 +23,9 @@
target-url (str "http://" (:data-bucket env)
".s3-website-us-east-1.amazonaws.com/"
target-key)]
(log/info "sending email to " (:import-failure-destination-emails env))
(s3/copy-object mail-bucket mail-key (:data-bucket env) target-key)
(ses/send-email {:destination {:to-addresses [(:import-failure-destination-email env)]}
(ses/send-email {:destination {:to-addresses (:import-failure-destination-emails env)}
:source (:invoice-email env)
:message {:subject "An email invoice import failed"
:body {:html (str "<div>You can download the original email <a href=\"" target-url "\">here</a>.</div>")