Description
When using the quarkus-mailer extension it is only possible to setup a single SMTP server configuration. In a SaaS context clients usually want to use their own STMP server.
Implementation ideas
I think the approach could be the same as with datasources. Where you can have multiple datasources configured and then specify a qualifier when injecting it (https://quarkus.io/guides/datasource#multiple-datasources).
@Nunalves let us a few days to revisit the multiple datasource code as we might be able to simplify it with the new Quarkus developments. If it's the case, it will be a good source of inspiration if you want to contribute the multiple SMTP support.
Provided @cescoffier is OK this is a good feature request.
/cc @geoand
I never thought we would need multiple SMTP :-)
After going through the motions of refactoring the multiple datasource handling, I think that we know have a good blueprint of how to do this with little friction.
I'll make a first pass on the mailer extension to simplify it's CDI configuration. That should pave the way for supporting multiple SMTPs.
https://github.com/quarkusio/quarkus/pull/9151 makes things much simpler so when it's merged then it should be a lot easier for someone to work on this issue
Most helpful comment
@Nunalves let us a few days to revisit the multiple datasource code as we might be able to simplify it with the new Quarkus developments. If it's the case, it will be a good source of inspiration if you want to contribute the multiple SMTP support.
Provided @cescoffier is OK this is a good feature request.
/cc @geoand