guardian / gibbons

Cleanup monkeys for the CAPI API keys table
0 stars 0 forks source link

Use SES email templates #5

Open regiskuckaertz opened 6 years ago

regiskuckaertz commented 6 years ago

Amazon SES supports templates and they rock 🎸

I could drop the Twirl dependency and improve throughput, by doing the following:

The latter would only require ⎡length(users) / 50⎤ requests.

The question is, how do I create a template in a CF script? Is it possible to reference an external file?

tomrf1 commented 6 years ago

It certainly looks possible - https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ses-template.html If you really want it defined in a separate file perhaps you can use AWS::Include - https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/create-reusable-transform-function-snippets-and-add-to-your-template-with-aws-include-transform.html

Does the performance gain justify the extra work?

edit: i didn't mean to close the issue...

regiskuckaertz commented 6 years ago

| Does the performance gain justify the extra work?

Definitely not a priority no, just something I can do in my spare time to squeeze time out of existing code 🤗