OutgoingSegmentTask¶
-
public class
OutgoingSegmentTask
extends ActiveTaskAdaptor¶ Creation Date: 9/10/2006
Author: Twinsen Tsang
Constructors¶
OutgoingSegmentTask¶
-
public
OutgoingSegmentTask
(SFRMMessageSegmentDVO sgtDVO, SFRMPartnershipDVO pDVO, SFRMMessageDVO msgDVO, PackagedPayloads payload)¶ Explicit Constructor.
Parameters: - sgtDVO – The payload need to be send out.
- pDVO – The partnership record associated to this segment.
- msgDVO – The message record associated to this segment.
- payload – The packaged payloads
Throws: - NullPointerException – If the message, partnership and segment is null.
Methods¶
execute¶
-
public void
execute
()¶ Execute the active task.
See also:
hk.hku.cecid.piazza.commons.module.ActiveTask.execute()
getMaxRetries¶
-
public int
getMaxRetries
()¶ Returns: return the max retries allowed for this active task.
getRetryInterval¶
-
public long
getRetryInterval
()¶ Returns: return the interval between each sending retry.
onFailure¶
-
public void
onFailure
(Throwable e)¶ The method is invoked upon the task fails to send. The message segment and message will treat as FAIL. with status DF (Delivery Failure). Also, if the outgoing segment is a RECEIPT, then the PAYLOAD segment corresponding to this RECEIPT is also treated as FAIL.
Parameters: - e – The failure cause.