Re: [exim] combining multiple incoming messages to same loca…

Top Page
Delete this message
Reply to this message
Author: Todd Lyons
Date:  
To: Don Walker
CC: exim-users
Subject: Re: [exim] combining multiple incoming messages to same local domain
On Wed, May 30, 2012 at 11:42 AM, Don Walker <donwalker@???> wrote:
> single message to multiple groups, all at the same domain, is being split
> into separate messages (one for each group) by the SMTP host.  When these
> separate messages arrive at the exim server, it is no longer able to
> suppress multiple messages to the same individual.  For example, if John Doe
> is a member of group1 and group3, and a message is sent to group1@???,
> group2@??? and group3@???, John Doe receives the message twice.
>
> Does anyone know a way for exim to combine such messages and process them as
> a single arriving message addressed to multiple groups?  Factors for
> combining would include a short time window (ie, the split messages arrive
> within seconds of each other), the same sender, and the same subject.


If it's a different message ID, then it's a different message, so the
behavior is consistent with design.

Having said that, this is me thinking out loud: store the actual
recipient and From, Date, and Subject headers in a database table or
memcache/mongo. When receiving a new message, if the subject headers,
and the date headers, and the from headers match a previously received
email for this actual recipient, drop the email. For the db case,
purge anything from the table older than $X minutes, where $X is some
value that works for you. For memcache/mongo, they will expire
according to whatever you set when you create the record.

...Todd
--
Always code as if the guy who ends up maintaining your code will be a
violent psychopath who knows where you live. -- Martin Golding