One of our needs is when an event happens - we need to send a message
(right now email message - but FAX / SMS etc... to be added soon).
The requirement is that this mechanism should be robust... if the mail delivery failed -
it should be retried...
(Also the first cut we have now calls Java Mail API - as this is a synchronous call - things look kind of sluggish).
I started looking at the docs - and came up with the following:
1. Instead of interfacing directly with the Java mail service - hand it over to the RabbitMQ server... (send it to a queue)
(use Spring AMQP support)
2. We can write a consumer that picks up the message from the queue - this consumer would then call java mail api
(take the onus of mail delivery)
3. Not sure how we can completely address the reliability concern
4. However, the call would be asynchronous now - hence production code would be fast...
Am I doing right? - any thoughts for improvement most welcome...
Thanks guys for this wonderful forum...
Joined: Jul 24, 2008
Is this question already answered in the docs?
I see mail support in Spring Integration -
With respect to what I wrote earlier - is this the right way to go - or is there anything already in Spring?
- thanks atul
subject: Using Spring+RabbitMQ for reliable email send?