Autor: Jasen Betts Data: Dla: exim-dev Temat: Re: [exim-dev] Message id format
On 2014-09-03, David Saez Padros <david@???> wrote: > Hi
>
> I was searching for an easy way to add message queue priorities
> to Exim and the easiest way would be to change the message id
> so one of it's characters is the message priority. This way queue
> sorting could be done just by sorting spool files in a special way
> without the need to read the header files.
>
> One possible candidate could be the first character of the process
> id as actually at least linux has a default of 32768 for the maximum
> pid number (which only takes up to 3 characters in base 36 and 2
> characters in base 64). I think even 5 characters will be enough
> for a pid number on a system allowing the larger maximum pid number.
> For systems were a pid number could be larger that this, this
> behaviour could be disabled. If i'm now wrong, at least Exim itself
> does not extract this number from the message-id in any place.
>
> If this makes sense i could write the changes need for this to
> work, basically:
>
> - option to enable/disable sorting on this character
> - changes in the queue sort algorithm comparision function
> - acl option to set the priority and re-generate the message-id
>
> the only thing remaining is that i have no clear idea about at which
> point in time is the message-id generated and the spool file written
> (after or before acl)
It's written before the DATA acl, but I think generated at the time of
the PRE-DATA acl (not sure if before or after)
If you can know the priority at the time of the pre-data ACL perhaps
you can instead modify the split-spool mechanism to put high priority
messages into a different directory.