During the Sending, Delivery and Notification of User- and SignalMesssage's it could happen that the message is not correctly sent, delivered or notified by the first attempt. Delivery or notification This can fail happen for several reasons, for instance a network timeout.
To provide a more reliable send, deliver and notification system, AS4.NET supports retrying when delivery or notification failsone of these operations fail. The retry deliver and notification functionality of the AS4.NET component is configured in the Sending Processing Mode and Receiving Processing Mode.
Processing Mode Configuration
Send Operation
The Sending Processing Mode can have a A <Reliability/>
where a <ReceptionAwareness/>
tag can be present. This element must have the following values configured in this structure:
<Reliability>
<ReceptionAwareness>
<IsEnabled>true</IsEnabled>
<RetryCount>3</RetryCount>
<RetryInterval>00:00:05</RetryInterval>
</ReceptionAwareness>
</Reliability>Reliabilty>
- The
IsEnabled
flag manipulates whether or not the operation should be retried on failure - The
RetryCount
defines the maximum number of retries that will be attempted - The
RetryInterval
will be the interval at which retries happen
Delivery and Notification Operations
The <Deliver>
element in a Receiving Processing Mode and the elements that are used for notification in both a Sending Processing Mode and a Receiving Processing Mode can have a <Reliability/>
that defines the retry-functionality.
A <Reliability/>
element must have the following values configured in this structure:
<Reliability>
<IsEnabled>true</IsEnabled>
<RetryCount>3</RetryCount>
<RetryInterval>00:00:05</RetryInterval>
</Reliability>
- The
IsEnabled
flag manipulates whether or not the operation should be retried on failure - The
RetryCount
defines the maximum number of retries that will be attempted the MaxRetryCount value used to determine how many retries could happen - The
RetryInterval
will be the interval in which retries happen
...
- The
<Deliver/>
tag can have aReliability
element - The
<ExceptionHandling/>
tag can have a<Reliability/>
element
That's all you need to do that needs to be done to enable the retry-functionality during the send, delivery or notification process.
Note that on certain failures, the retry will NOT happen even when it's configured this way. This could happen when the failure that occured is considered FATAL (for example: a 401 HTTP response code which means that there's a problem with permissions). The reason for this is that even when an retry is configured, the message will still fail the second time arround, therefore no retry will happen.
Note: Retryable deliver/notification is only available in version AS4.NET v.3.1.0 and beyond.