In-line delivery

From Halon, SMTP software for hosting providers
Jump to: navigation, search

The Halon SMTP software is capable of doing queue-less, in-line delivery resulting in

  • fully fail-safe, fault-tolerant SMTP transactions
  • fully elimination of backscatter problems
  • fully transferring the responsibility of error reporting and queuing to the sender

This feature allows the system to fail (hardware failure, etc) at any moment during operation without the risk of loosing any data. The implementation will not confirm message acceptance (220 OK) until the message is accepted by the receiving backend mail server.

Enabling in-line delivery

Enabling in-line instead of queued delivery is as simple as using the DirectDeliver function instead of the normal Deliver (usually found in the end of the DATA flows) or overriding Deliver() by adding (at the top of the DATA flow, or perhaps as an included file):

function Deliver() {
    if (
count($recipientdomains) == 1// If multiple domains, they might be on different servers
builtin Deliver();

The feature has a few defined limitations, in order to prevent odd behaviours such as message duplication and unknown message delivery statuses on multiple recipients. These limitations usually cause an runtime exception, and include:

  • Delivery has to be made to a single backend server (it cannot operate in lookup-mx/outbound mode)
  • Per-recipient modification to a single message cannot be done (eg. SetHeader("X-Recipient", $recipient))
  • If one recipient fails during DirectDeliver (because of the backend server), the message will not be delivered (simply solved by enabling recipient filtering in the RCPT-TO flow).