Email List Migration!
As I wrote almost a month ago, I needed to move the site to a new email subscription system, and that took some time away from photo editing and writing.
I've now completed the migration.
If you currently receive email updates from this site, please let me know if they're displaying okay, or if there is any unexpected behavior. If not, why not consider subscribing?
For a little information on the how and why, continue reading after the break.
Why Change? (TLDR; It's Google's Fault)
When I first set up this site, I made sure that it was able to generate an RSS feed -- a special XML file that contains information on the site's posts. As much as I wish RSS feeds were mainstream, and though they were prominently featured on many blogs in the heyday of Web2.0, they are primarily used by a specialized audience.
Many normal people sign up for site updates via emails, or even straight-up email lists. Personally, I am happy to consume some information this way, but a little hesitant -- I wouldn't want updates from the ~500+ blogs I follow to wind up in my email. I might forget to pay my bills.
So, out of a sense of inertia more than anything else, I initially setup an RSS Feed -> Email service using FeedBurner, which I used back in my BlogSpot days. FeedBurner is a Web2.0 era RSS feed-augmenting startup that was purchased by Google for a princely sum, and whose products appear to have languished since then. FeedBurner was founded in 2003, and certainly its web design doesn't seem to have changed since then.
Unsurprisingly, with Google being Google, they decided to discontinue the Feedburner Email Service, which meant that I needed something else.
Alternatives and Their Drawbacks
There are alternate services that can transmute my RSS feed into an email subscription. It's just... most of them cost money and are aimed at large companies with marketing budgets. Their free versions are either limiting or cumbersome. In essence, they provide no additional value compared to Feedburner.
The first service I looked at was called follow.it, and they're pretty prominently marketing themselves as a Feedburner Email alternative. They seem like they could be a nifty service to use...
But for me, the issue was this: "Tailoring of subject line" is a premium feature.
So, unless I paid up, each email subject would say "Where is Steve? (Posts) - new message."
I fooled around for a little while with prominent email marketing toolkit MailChimp, but I found it to be cumbersome and overkill for my use case. I needed to define custom templates using a proprietary language. Shortly thereafter, I accidentally introduced a typo into my template for images, and the resulting syntax error still left things rendering correctly everywhere but MailChimp.
Any other service I looked into seemed more expensive, more enterprise-oriented, and less suitable for a scrappy operation like my own.
Plus, I am deliberately using as little tracking and analytics as possible on this site.
So, I figured it wouldn't be too hard to write my own.
What I Wrote
I wrote some Python code that runs on Azure Function, a server-less computing tool in Microsoft's Enterprise Cloud. Basically, what this means is that a remote server runs my code on demand, and otherwise no hardware is involved. This may increase latency, but decreases cost since I don't pay for idling hardware.
The main function runs on a daily timer, and downloads a copy of the site's RSS feed. If it has been updated since the last run, then an email message is generated and sent to a list of subscribers. I'm using the SocketLabs Injection API to send email, and do not anticipate that I will exceed the free tier's limit of 2k emails per month anytime soon.
The subscriber list is also managed through separate Azure function calls. These return text/html responses designed to resemble the webpage.
The actual email templates are pretty ugly HTML. It turns out that different email providers are pretty damn inconsistent about which parts of the HTML spec they'll render, so my goal was cross-platform compatibility. Hopefully, this will improve over time.
If you want to check it out, the full code is OpenSource. It's probably pretty brittle, so I would recommend making substantial modifications if you wanted to do something similar. The repository is here.
Also, using Azure functions will still cost me money, but compared to a service like follow.it, it should cost me 1/5 or 1/100 as much, depending on growth over time.
By this, I mean I anticipate that Function should cost me less than a penny per month at current rates, while follow.it would have charged a nickel.
Hours of labor in return for pennies is a poor return on investment, but I assure you, I learned a lot about serverless computing, email templating, and sundry other topics in the process.
And that was a great return on the time investment.
Hopefully I don't screw up and accidentally send integration test messages to my subscribers. (Don't worry, I have separate prod/test setups...)
And hopefully you enjoy and continue to enjoy reading.
Thanks for reading!
If you enjoyed this post, you might enjoy these 5 similar posts:
- 2021-06-21 —How to Liveblog on a Static Site, Or: A Thoughtless Kludge
- 2021-04-24 —Towards Lighter Weight Youtube Embeds
- 2019-12-17 —Minor Improvements
- 2021-06-29 —A Sojurn on Maui (May/June 2021)
- 2022-05-04 —How I Generate Maps on My Static Site With OpenLayers and Zola