|
AXL RADIUS Server API V3 | |||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
ObjectRetransmission
Client retransmission class.
The client should try to avoid congestion and synchronization problems by using this class to determine time outs to use when waiting for reply packets. Congestion failure occurs usually when a server is overwhelmed with requests from a large number of clients will use a short fixed timeout for retransmissions. This class will use progressively longer time outs until a maximum time out is reached. If more retries are required the Retransmission class will restart with the minimum time out.
To avoid synchronization problems that can occur when a number of clients start to synchronize their retransmissions some 'jitter' is added to the time out period so that the wait time is not measured in one second granularity.
Typically this class will be used to back off if a transmission fails and an exception is thrown. It will add extra time between retransmissions of a client packet.
This performance is based on four variables:
| Constructor Summary | |
Retransmission(int minimumTimeout,
int maxTimeout,
int jitter,
int count)
Constructor. |
|
| Method Summary | |
void |
cancel()
Cancel this retransmission wait. |
long |
getTimeout()
Calculate the new time out based on the last time out. |
static void |
main(String[] a)
|
boolean |
pause()
Pause between each retry. |
void |
reset()
Reset the time out calculations for a fresh time out. |
| Methods inherited from class Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public Retransmission(int minimumTimeout,
int maxTimeout,
int jitter,
int count)
minimumTimeout - On a retransmission
this would be the minimum time out. For example it could be 5 seconds.maxTimeout - This is the maximum time out possible. For example it could
be 60 seconds.jitter - This is the 'inaccuracy' in the actual timeout measured in percent
and is applied randomly within this range.
It prevents clients from all synchronizing to some exact time out
like once each second. With a jitter value of 20 the first time out might
occur in .8 seconds or 1.2 seconds within the range of the time out.count - The number of retries to make. This is the number of retries beyond
the first attempt.| Method Detail |
public final void cancel()
pause().
public long getTimeout()
public static void main(String[] a)
public final boolean pause()
public void reset()
|
AXL RADIUS Server API V3 | |||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||