com.healthmarketscience.rmiio
Class RemoteRetry.SimpleAlways

java.lang.Object
  extended by com.healthmarketscience.rmiio.RemoteRetry
      extended by com.healthmarketscience.rmiio.RemoteRetry.Always
          extended by com.healthmarketscience.rmiio.RemoteRetry.SimpleAlways
Enclosing class:
RemoteRetry

public static class RemoteRetry.SimpleAlways
extends RemoteRetry.Always

Simple implementation of Always retry strategy which uses the backoff strategy from RemoteRetry.simpleBackOff(int, org.apache.commons.logging.Log). Please read warning in RemoteRetry.Always before using.


Nested Class Summary
 
Nested classes/interfaces inherited from class com.healthmarketscience.rmiio.RemoteRetry
RemoteRetry.Always, RemoteRetry.Caller<RetType>, RemoteRetry.Never, RemoteRetry.Simple, RemoteRetry.SimpleAlways, RemoteRetry.VoidCaller
 
Field Summary
 
Fields inherited from class com.healthmarketscience.rmiio.RemoteRetry
LOG, NEVER, RUNTIME_CLASS, SIMPLE, SIMPLE_ALWAYS
 
Constructor Summary
RemoteRetry.SimpleAlways()
           
 
Method Summary
 void backOff(int numRetries, org.apache.commons.logging.Log log)
          Should delay for some implementation defined amount of time (to give the callee, network, etc.
 
Methods inherited from class com.healthmarketscience.rmiio.RemoteRetry.Always
shouldRetry
 
Methods inherited from class com.healthmarketscience.rmiio.RemoteRetry
call, call, call, call, call, call, call, call, callImpl, simpleBackOff
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RemoteRetry.SimpleAlways

public RemoteRetry.SimpleAlways()
Method Detail

backOff

public void backOff(int numRetries,
                    org.apache.commons.logging.Log log)
Description copied from class: RemoteRetry
Should delay for some implementation defined amount of time (to give the callee, network, etc. time to recover) given the number of previous reattempts. Will be called iff shouldRetry() returned true. Good implementations should implement some sort of increased delay based on the number of reattempts.

Specified by:
backOff in class RemoteRetry
Parameters:
numRetries - number of previous reattempts
log - debug log


Copyright © 2006–2016 Health Market Science. All rights reserved.