Danny Angus wrote:
But to say it is outside of the current Mailet API, is wrong IMO. The
Mailet API is for the routing and handling of emails -- all we are
talking about is allowing the developer to make this decision much
faster/earlier.
Actually the mailet API implies a particular process which starts with
the full content of the message having already entered the system
okay i can buy that. As with the ServletAPI, i think we should consider
the possible of both. For example, the ServletAPI allows a developer to
process the incoming stream themselves if they want to kill the
connection at any point they can.
BTW - I don't suggest for a minute we have a "getMailetInputStream()"
method, as that is way too ugly for even consideration! :)
FastFail implies that an interest in the conversation carried out
during the protocol can result in decisions being taken *before* the
message has entered the system.
Well before the complete message has arrived. But surely we are already
protocol dependent. Think about it.
We have data that arrives on "MAIL FROM" and "RCPT TO" and that data is
presented in the Mailet API (aka the Matcher).
HOWEVER ... this information is not necessarily in the actual "DATA"
part. Therefore, if one was to dump the mail packet to the file system
(using whatever) then a lot of this data is lost already.
So to say the Mailet API has nothing to do with protocol is
contradicting the current API and specification. Is it not?
So my thought process is not to actually change anything, but to make
the Matcher stuff be called as soon as any email data arrives; not just
when they are all in.