This post is mostly about the newest release of Nodemailer. For the license changing rant, scroll down past the feature list.
It’s been a while since a major release of Nodemailer happened and now it’s finally here, the initial version of Nodemailer 3! This update brings a lot of breaking changes. I hope to write a separate blog post for each of these but for now, here’s what changed:
- License changed from MIT to EUPL-1.1. This was possible as the new version of Nodemailer is a major rewrite. The features I don’t have ownership for, were removed or reimplemented. If there’s still some snippets in the code that have vague ownership then notify me at [email protected] about the conflicting code and I’ll fix it
- Requires Node.js v6+ as a lot of ES6 specific features are used. Some make life easier (eg. classes versus Function.prototype), some make the code better (using let instead of var eliminates several possible memory leak scenarios)
- All templating is gone. It was too confusing to use and to be really universal a huge list of different renderers would be required. Nodemailer is about email, not about parsing different template syntaxes
- No NTLM authentication. It was too difficult to re-implement. If you still need it then it would be possible to introduce a pluggable SASL interface where you could load the NTLM module in your own code and pass it to Nodemailer. Currently this is not possible.
- OAuth2 authentication is built in and has a different configuration. You can use both user (3LO) and service (2LO) accounts to generate access tokens from Nodemailer. Additionally there’s a new feature to authenticate differently for every message – useful if your application sends on behalf of different users instead of a single sender.
- Improved Calendaring. Provide an ical file to Nodemailer to send out calendar events.
There’s also some non-breaking changes:
- All dependencies were dropped. There is exactly 0 dependencies needed to use Nodemailer. This brings the installation time of Nodemailer from NPM down to less than 2 seconds
- Delivery status notifications added to Nodemailer
- Improved and built-in DKIM signing of messages. Previously you needed an external module for this and it did quite a lousy job with larger messages. The updated version processes messages as streams and also is able to cache parts of the data to disk if the message is very large
- Stream transport to return a RFC822 formatted message as a stream. Useful if you want to use Nodemailer as a preprocessor and not for actual delivery.
- Sendmail transport built-in, no need for external transport plugin
See Nodemailer.com for full documentation. I hope you’ll enjoy the new features!
PS. Several people have asked me about the license change. Why use such an esoteric license like EUPL (European Union Public Licence – EUPL v.1.1)? And why a copyleft license, whats wrong with good old MIT/BSD?
EUPL is very similar to GPLv2 as these licenses are more or less compatible. EUPL has the advantage over GPL of having an official translation of the license text in the Estonian language as all EU documents are translated into all EU languages. I don’t know any other open source license that has such translation. Additionally GPL is more US specific while EUPL is EU specific and Nodemailer is built in EU (in Estonia), so its a natural choice if copyleft license is preferred.
So, why copyleft?
I’ve been building Nodemailer for the last 6 or 7 years and while it has been a source of great mental satisfaction (you know, solving some really difficult problems, squashing hard to find bugs, studying a myriad of email related RFC’s and so on) then it’s been a lousy project in financial terms. I’ve been collecting donations since day one and the grand total I’ve received during this time is around $500 (the sum would be double of that if I hadn’t spent the bitcoin I received long before the price surge). And these donations were made mostly by fellow developers like myself (huge props to all who have ever donated to any of my projects, I really appreciate it!).
Nodemailer, at least the core of it, is not a community project. Obviously I’ve received a lot of help during the years but nevertheless I consider it a solo project, every feature and every change directly translates back to the time I’ve spent building this project.
The problem how I see it, is that Nodemailer is not used only by fellow developers like myself, it is also used by larger companies that do not tend to give anything back. I’m aware that no company is successful because of using Nodemailer, I’m also aware that using Nodemailer saves a lot of developer hours because of the easy to use API and the Just Works approach. A lot of the value is under the hood – for example Nodemailer gives its best to build as compliant messages as possible to avoid being marked as spam (there’s a ton of different compliancy tests spam filters usually check for and messages generated by Nodemailer should pass them all). Nodemailer also tries to be as resource friendly as possible – this in turn means faster sending speed and better performance. To arrive into such state has taken huge efforts on my side and I see companies getting a lot of value out of it but I don’t see any gains for myself.
In short, that’s why I decided to change the license. I don’t feel like I should be sponsoring big companies with my unpaid time. I can’t (and I don’t want to) revert already published versions but for the new stuff I go with copyleft. For most people this should be just as fine as anything else. If, for whatever reason, copyleft is not acceptable, then there’s always the option to purchase a commercial license without the limitations of copyleft or use something else to send the emails, for example vendor provided API clients or some other SMTP client.
13 Replies to “Nodemailer v3.0.0”
I’m a big fan of strong copyleft but can you at least dual-license with the GPL so that people who are familiar with that license can feel comfortable?
I published a FLOSS exception (link) for Nodemailer that should cover the compatibility for different versions of GPL (EUPL licensed code can be used in GPLv2 projects out of the box but this does not apply for other GPL versions)
There is no rational reason to be “a big fan of strong copyleft” – it benefits no one but the lawyers. A significant and growing number of people recognize that software encumbered by pages of legalese threats is NOT free software, and boycott it for philosophical if not practical reasons. Restrictive license is the 21st century equivalent of a leaper’s bell. The author will see a drop in users, donations, and even employment prospects as the result of this extremely foolish decision. Read copyfree.org
I think the point is that the developer doesn’t care about a drop in users. After years of effort he’s only received $500 so a drop in money is no threat either. Really, why should the author spend the time and effort to help random corporations at all? Even if everyone “boycotted,” the financial change to the author would essentially be the same.
Nice logo. Good luck with your efforts. I for one think the license change is a good idea.
Fantastic work on Nodemailer and we support your decision to get paid for your hard work! I look forward to purchasing a company license as soon as we upgrade to 3.0 – very soon!
Thanks for the support! I’m always happy when my work helps companies like MixMax that actually understand the value of the ecosystem around them.
Now a significant fraction of potential users will boycott you.
Doesn’t matter, I’ve lost interest in getting more users or fame for Nodemailer anyway. The last time I was excited about the “star” count of Nodemailer in Github was when it reached 500 which was like 5 years ago.
Thank you for making such a great tool. I’m a huge fan of your work!
I’m not a lawyer, so I’m finding it really difficult to understand what does this copyleft mean in practice?
Greetings from Finland! 🙂
Thanks! The license is EUPL which is kind of a copyleft license like GPL but there’s also the FLOSS exception list for Nodemailer (link) that should make Nodemailer also compatible with LGPL. So under these terms, I would assume that if you install Nodemailer from npm and do not distribute it yourself then nothing should change for you.
Just want to say thank you for your contribution to the developer community all these years. I whole-heartedly support your decision, and understand why you had to make the change.