I'm managing a mail gateway that handles 250.000 msgs/day on average. Mail
comes from Internet towards internal servers and is filtered (spam, virus) at
the gateway before entering the vpn link. System works quite well, except on
cases where some large mails (that are really wanted adds) collapse the vpn
links for hours making small and often more important mails to get queued.
I would like to know if it is possible to implement some kind of queue
running precedence, in which I could mark messages with a priority based on
some filter (side, headers, etc) and then only process low priority mails
with que queue runner when there are no hight priority mails waiting to be
delivered with retry time reached.
The algorithm would be:
At reception: each mail passes through a filter which assigns a priority
value, from 0 (max priority) to 99 (lowest priority). Mails with priority
other than 0 are queued instead of sent directly.
The queue runner sorts mails in the queue based on the priority, and starts
sending those with priority 0, then priority 1 and so on. When one category
is ended, the queue should be read again to see if new "higher priority"
mails have arrived the queue.
Is this possible today? Any chance to get it implemented? Any help to
implement it?