You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It's not generally legal to do this, but the PIPELINING extension (RFC 2920) allows it for certain commands, when advertised by the server. Specifically from section 3.1:
In particular, the commands RSET, MAIL FROM,
SEND FROM, SOML FROM, SAML FROM, and RCPT TO can all appear anywhere
in a pipelined command group. The EHLO, DATA, VRFY, EXPN, TURN,
QUIT, and NOOP commands can only appear as the last command in a
group since their success or failure produces a change of state which
the client SMTP must accommodate. (NOOP is included in this group so
it can be used as a synchronization point.)
Note that you have to wait for the response from DATA, which may be an error or a success, and even if an earlier command returned failure, DATA may return success, at which point you have to provide it with valid data.
I guess Data() should return a writer + error though, in addition to the explicit Wait() (which would not be necessary to call under usual circumstances). Thoughts?
Right now clients always wait for the server reply for a command before sending the next one. This causes some unnecessary latency due to roundtrips.
Possible extended API to allow clients to send command batches:
The text was updated successfully, but these errors were encountered: