public class LoadBalancerRetrySameServerCommand<T>
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
protected ExecutionInfo |
executionInfo |
protected ExecutionContextListenerInvoker<?,T> |
listenerInvoker |
protected LoadBalancerContext |
loadBalancerContext |
| Constructor and Description |
|---|
LoadBalancerRetrySameServerCommand(LoadBalancerContext loadBalancerContext) |
LoadBalancerRetrySameServerCommand(LoadBalancerContext loadBalancerContext,
com.netflix.client.RetryHandler retryHandler) |
LoadBalancerRetrySameServerCommand(LoadBalancerContext loadBalancerContext,
com.netflix.client.RetryHandler retryHandler,
ExecutionContextListenerInvoker<?,T> listenerInvoker) |
| Modifier and Type | Method and Description |
|---|---|
protected com.netflix.client.RetryHandler |
getRetryHandler() |
T |
retryWithSameServer(Server server,
LoadBalancerExecutable<T> executable)
Take a server and
LoadBalancerExecutable to execute the task
on the server with possible retries in blocking mode. |
rx.Observable<T> |
retryWithSameServer(Server server,
rx.Observable<T> forServer)
Gets the
Observable that represents the result of executing on a server, after possible retries as dictated by
RetryHandler. |
protected final LoadBalancerContext loadBalancerContext
protected final ExecutionContextListenerInvoker<?,T> listenerInvoker
protected volatile ExecutionInfo executionInfo
public LoadBalancerRetrySameServerCommand(LoadBalancerContext loadBalancerContext)
public LoadBalancerRetrySameServerCommand(LoadBalancerContext loadBalancerContext, com.netflix.client.RetryHandler retryHandler)
public LoadBalancerRetrySameServerCommand(LoadBalancerContext loadBalancerContext, com.netflix.client.RetryHandler retryHandler, ExecutionContextListenerInvoker<?,T> listenerInvoker)
protected final com.netflix.client.RetryHandler getRetryHandler()
public rx.Observable<T> retryWithSameServer(Server server, rx.Observable<T> forServer)
Observable that represents the result of executing on a server, after possible retries as dictated by
RetryHandler. During retry, any errors that are retriable are consumed by the function and will not be observed
by the external Observer. If number of retries exceeds the maximal retries allowed on one server, a final error will
be emitted by the returned Observable.forServer - A lazy Observable that does not start execution until it is subscribed topublic T retryWithSameServer(Server server, LoadBalancerExecutable<T> executable) throws java.lang.Exception
LoadBalancerExecutable to execute the task
on the server with possible retries in blocking mode.java.lang.Exception