Hard and Soft Bounces

Bouces are categorized as hard or soft bounces based on certain criteria.

Hard Bounce

A Hard Bounce indicates that an email cannot be delivered because of a permanent error. For example, a permanent error is when a mailbox does not exist for a particular domain. There is no point in continuing to attempt to deliver current or future messages to the address as it can no longer accept email.

Soft Bounce

Soft Bounces are when an email cannot be delivered to an address because of a temporary error. Unlike a hard bounce, a soft bounce indicates that it is possible to deliver to the address at some point in the future. An example of a soft bounce is a mailbox full response.

Connect using Direct Mail Sending

The following diagram illustrates how Connect uses Direct Mail Sending.

images/download/attachments/56624872/bounce2.jpg


CUSTOMER_QUEUE Status Codes

There are several STATUS_CODES that are used in the CUSTOMER_QUEUE.


Table 1. List of CUSTOMER_QUEUE Status Codes

Status Code

Description

public static final int MSG_NOT_SENT = 0;

Status: Message is not sent

public static final int MSG_ATTEMPTED = 2;

Status: Message was attempted to be sent

public static final int MSG_SENT = 1;

Status: Message is sent

public static final int MSG_NOT_ATTEMPTED = 4;

Status: Cannot send message (e.g. content is not yet available)

public static final int MSG_NOT_ATTEMPTED_REASON_QUIET_PERIOD = 5

Status: Cannot send message because its campaign is in quiet period

public static final int MSG_PART_SENT = 6;

Status: Message part has been sent

public static final int MSG_IN_TRANSIT = 7;

Status: Message currently in transit

public static final int MSG_REJECTED_REASON_API_LIMITS = 8;

Status: Message rejected due to API limits being reached

public static final int MSG_REJECTED_REASON_TEMP_FAILURE = 9;

Status: Message rejected due to a temp failure

public static final int MSG_CREATED = 10;

Status: Status code set immediately after a MessageProtocol is created as a result of a campaign execution such that the customer_queue record is skipped in the next execution step when the execution is interrupted for various reasons, priority being one

public static final int NO_DYNAMIC_CONTENT = 102;

Error: No dynamic content

public static final int BAD_MERGE_TAG_FIELD = 103;

Error: Bad merge tag

public static final int DELIVERY_FAILED = 104;

Error: Delivery failed

public static final int NON_BOUNCE_FAILURE = 105;

Error: Message cannot be sent for a non-bounce reason (e.g. content does not exist). This will not count toward an unsubscribe byy the customer.

public static final int TLS_CONNECTION_FAILURE = 106;

Error: Message cannot be sent because it requires a TLS connection which is not available

public static final int DECRYPT_ATTACHMENT_FAILURE = 107;

Error: Message cannot be sent because it requires decryption

public static final int NO_SMS_NUMBER = 108;

Error: No SMS number exists for the message

public static final int EMAIL_SEND_ATTEMPT_EXHAUSTED = 109;

Error: The number of email send attempts is exhaused based on the system parameter CM.MaximumSendAttempts

public static final int SYSTEM_TERMINATED = 999;

Note: '999' is only maintained in MESSAGE_HISTORY table when the CUSTOMER_QUEUE records with a status_code = 0 are archived and the INSTANCE_QUEUE row was disabled or terminated. This prevents duplication of constants into MessageHistoryRow, since the status codes mean the same thing for both tables.


Scenario 1: Message Not Accepted by Destination SMTP Server

There is an error when Mail Sender attempts to execute the SMTP protocol with the destination SMTP server. Please refer to RFC-821 for more details. The following is a summary of codes and their description:

  • 2XX - Positive Completion

  • 5XX - Negative Permanent (a permanent error)


Note: Any network errors while establishing a connection or when executing the SMTO protocol are considered Temporary Errors.


For a permanent error: Mail Sender (using ComposerSyncLogs) updates CUSTOMER_QUEUE with status_code=104

For a temporary error: Mail Sender (using ComposerSyncLogs) updates CUSTOMER_QUEUE with status_code=2 (mail attempted). Another attempt to send all email is made at a later date.

Counters defined in COUNTER_MASTER where creator_name=Mail Sender are updated by the mail sender.

Scenario 2: Message accepted by destination SMTP server

When a message is accepted: Mail Sender updates CUSTOMER_QUEUE with the status_code=1.

Counters defined in COUNTER_MASTER where creator_name=Mail Sender are updated by the mail sender.

Scenario 3: Message accepted by destination SMTP server but sends a failure message back to the connect mail receiver (to the address specified in the email from field sent by Connect)

Stage1: Destination SMTP server accepts email.

  • Connect considers the message successfully sent when the message is accepted by the destination SMTP server. The CUSTOMER_QUEUE is updated with status_code=1.

  • Counters defined in COUNTER_MASTER where creator_name=Mail Sender is updated by mail sender.


Stage 2: Destination SMTP Server sends a failure reply to Connect MR.

  • When Mail Receiver receives a reply from the destination SMTP server, it applies the Reply Handler as specified above.

  • MSG* Tables are updated for the number of bounces and number of unsubscribe replies.

  • Counters defined in COUNTER_MASTER where creator_name=Mail Receiver/Processor are updated.


Connect using Mail Farm

The following diagram illustrates how Connect uses a mail farm.

images/download/attachments/56624872/bounce3.jpg


Mail farms usually accept all email coming from the Connect Mail Sender unless there are network issues between the Connect mail sender and the mail farm. As far as Connect Mail Sender is concerned any email accepted by the mail farm is considered to be successfully sent. If there is an issue when the mail farm tries to relay the email, it is up to the mail farm to retry or send a failure reply back to the mail receiver depending on how the mail is configured.

Scenario 1: Message not accepted by Mail Farm

If the mail farm rejects an email from the mail sender and if it is a permanent error, mail sender updates CUSTOMER_QUEUE with status_code=104.

Note: This is very rare since mail farms accept any incoming email then try to relay the email to the destinations.

If there is a temporary error, Connect tries to resend the same email a certain number of times as specified by the system parameter Max number of retries (Notification | Advanced) or until the email is sent. Since retry attempts occur immediately, Connect does not update CUSTOMER_QUEUE with status_code=2 like it does when using DMS.

Scenario 2: Message accepted by Mail Farm

When mail farm accepts an email, Connect considers that email successfully delivered.

Counters defined in COUNTER_MASTER where creator_name=Mail Sender are updated by mail sender.

Scenario 3: Message accepted by Mail Farm. If the mail fails after repeated attempts to send, Mail Farm sends a failure reply to Connect MR:

Stage1: Mail Farm accepts email.

  • Connect considers the message successfully sent when the message is accepted by the Mail Farm. The CUSTOMER_QUEUE is updated with status_code=1.

  • Counters defined in COUNTER_MASTER where creator_name=Mail Sender are updated by mail sender.


Stage 2: Mail Farm sends a failure reply to Connect MR.

  • When mail receiver gets a reply from the destination mail farm, it applies the reply handler as specified above.

  • MSG* Tables are updated with the number of bounces and number of unsubscribe replies.

  • Counters defined in COUNTER_MASTER where creator_name=Mail Receiver/Processor are updated.


Scenario 3: Message accepted by Mail Farm. Mail Farm successfully sends the email to the destination email address. Destination SMTP Server sends a failure message back to Connect Mail Receiver (to the address specified in the email from field sent by Connect).

Stage1: Mail Farm accepts email.

  • Connect considers the message successfully sent when the message is accepted by the destination SMTP server. The CUSTOMER_QUEUE is updated with status_code=1.

  • Counters defined in COUNTER_MASTER where creator_name=Mail Sender are updated by mail sender.


Stage2: Destination SMTP server accepts email from Mail Farm.

Mail Farm successfully sends the email to the destination SMTP server. There is no change in Connect when this happens.

Stage 3: Destination SMTP Server sends a failure reply to Connect MR.

  • When Mail Receiver receives a reply from the destination SMTP server, it applies the Reply Handler in the order specified above.

  • MSG* Tables are updated for the number of bounces and number of unsubscribe replies.

  • Counters defined in COUNTER_MASTER where creator_name=Mail Receiver/Processor are updated here.