[Dovecot] Discard duplicate messages at delivery?
Hello,
I am using dovecot 1.2.9, and the sieve plugin for filtering incoming messages into specific folders. The MTA is postfix, and deliver is called using the "mailbox_command = /usr/lib/dovecot/deliver" directive.
Is it possible to make dovecot's deliver discard duplicate messages?
With cyrus there is a duplicatesuppression directive which works well (http://cyrusimap.web.cmu.edu/imapd/overview.html#duplicate). With procmail, this can be done with the following recipe, but I did not found an equivalent for dovecot:
# One often receives duplicate messages for cross-postings to mailing # lists, or explicit replies to a post from you in addition to the # mailing list message. # # The following recipe eliminates all duplicate messages. It tells # formail(1) to keep a cache file of the Message-IDs of the most # recent messages you've received. Since Message-IDs are guaranteed # unique for distinct messages, they are ideally suited to weed out # duplicates. # :0 Wh: msgid.lock | formail -D 65536 .saves.msgid
Thanks,
Nicolas
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
On Tue, 12 Jan 2010, Nicolas KOWALSKI wrote:
Is it possible to make dovecot's deliver discard duplicate messages?
No, currently not.
BTW: "if two copies of a message with the same message-id and the same envelope receipient are received." I know that MessageIDs are supposed to be globally unique, but one cannot count on it.
This feature had been asked several times; it should be possible to code using the "extdata" plugin API in newest Sieve, see the last messages in the list.
Regards,
Steffen Kaiser -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.6 (GNU/Linux)
iQEVAwUBS0ySrb+Vh58GPL/cAQIxzgf/Qw2o2uXxTAruoVCPnj1RQNq4VOWfdqJm A7AiZmL/YYnwOx3GMJI8R48Fy5s7HzANmj5uibyp/80/tTgvaCSndJ6MxRqFSygd Gj/nwsg+LHQi2GJJ2T908yrEvpX4Gv6Roy1ZxsheorfM+RYPseAyu6iR3z88AEGX 0VlZagPBdNQ5U+7TJTrLQgpM92W8UUuWAYE4j0CHqEFbLiPyS8dvqhvpVTjdqrtb ZdKufF9FrSPKoTnrUpiGRECfensbFgxadswYSxsbzA7qIM1FcXfPP0Pnkp0GmBPY SB+2eCLUG7K5THy9NQHSEfnP3wm1NtRKaHuloQFnswUd/cK8JY3ywg== =wyop -----END PGP SIGNATURE-----
Steffen Kaiser skdovecot@smail.inf.fh-brs.de writes:
On Tue, 12 Jan 2010, Nicolas KOWALSKI wrote:
Is it possible to make dovecot's deliver discard duplicate messages?
No, currently not.
Ok.
BTW: "if two copies of a message with the same message-id and the same envelope receipient are received." I know that MessageIDs are supposed to be globally unique, but one cannot count on it.
I agree, but IMHO, most of the times it is ok, and by using a short lifetime for the Message-IDS stored, the risk of having false duplicates is even less important.
Thanks for your reply,
Nicolas
participants (2)
-
Nicolas KOWALSKI
-
Steffen Kaiser