Re: [EXIM] local_part in an added header problem

Página superior
Eliminar este mensaje
Responder a este mensaje
Autor: Philip Hazel
Fecha:  
A: djc
Cc: David Shaw, exim-users
Asunto: Re: [EXIM] local_part in an added header problem
On Fri 22 May, Dave C. wrote:

> Being only slightly familiar with the way exim passes an open SMTP
> connection to another instance of exim to re-use, I would suggest each
> invokation passing a number to the next indicating how many messages
> had been passed, and incrementing it before passing it again..


It already does this. The option is called batch_max in the smtp transport.

> If I'm off the mark about how it works just ignore me..


You are off the mark in this instance, because the discussion is about re-using
an SMTP connection *within the same message*. The creation of another instance
of Exim is for sending a different message down the same connection. Within the
same message, if there are lots of addresses for the same host, it currently
runs each subset of addresses (up to max_rcpt) in a separate run of the
transport, and these may proceed in parallel if the configuration allows it.

I've looked around a bit further in the code. What I can make it do is to use
the same connection for each group of max_rcpt addresses, *provided that the
copies of the message that are to be sent are identical*. The original cause of
this thread was the failure of headers_add on a router when two addresses were
for the same host. The work-round was to put headers_add on the transport and
set max_rcpt to 1 so that each address caused a separate copy of the message to
be sent.

I have in fact fixed the original problem, but with each recipient required to
receive different headers, it is still going to run the transport twice, and
each run will set up a new TCP/IP connection, either in parallel or serially,
dependent on the configuration (and maybe hand that connection over to another
Exim for another message). I don't like the idea of hanging on to one
connection just in case another set of addresses could use it - at least not
given the current implementation, which is complicated by the parallelism. Now,
if I'd written it differently from the start...

I am now not really convinced that it is worth trying to do anything.

-- 
Philip Hazel                   University Computing Service,
ph10@???             New Museums Site, Cambridge CB2 3QG,
P.Hazel@???          England. Phone: +44 1223 334714



--
*** Exim information can be found at http://www.exim.org/ ***