Hello all,

As off 20/09/2019 delays are not supported on top of RabbitMQ MailQueue.

While this is not a problem for a "Mail Delivery Agent" server, this is
a major concern for a "Mail Exchange" server, as stated out by @splainez
on the gitter channel.

A possible implementation came to my mind regarding this concern:

 - When a delay is specified, we save the message in the object storage,
 fire a message on a **MailQueueDelayExchange**, and persist it on the
MailQueueView.
 - Each James listens on a single Queue plugged to the
**MailQueueDelayExchange**.
 - For each incoming message, the receiver will position a timer until
planned delivery (date).
 - Upon timer completion, we ack the message of MailQueueDelayExchange,
then we put the corresponding message in the mail RabbitMQMailQueue (no
need to update the mailQueueView nor store again the blob).
 - Upon connection loss, the message will be nack and will be then
handled by another s/consumer/jamesServer/.

Obviously:
 - We need synchronized clocks "best effort" - think NTP
 - This solution can duplicate emails upon connection loss - a local
James needs invalidate the entries he is waiting for upon connection loss.

If you agree with such a technical solution, then I can write a JIRA
ticket for it, to allow potential contributors to work on it.

Cheers,

Benoit

---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscr...@james.apache.org
For additional commands, e-mail: server-dev-h...@james.apache.org

Reply via email to