Class LoadBalancerProperties.Retry
- java.lang.Object
-
- org.springframework.cloud.client.loadbalancer.LoadBalancerProperties.Retry
-
- Enclosing class:
- LoadBalancerProperties
public static class LoadBalancerProperties.Retry extends Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classLoadBalancerProperties.Retry.Backoff
-
Constructor Summary
Constructors Constructor Description Retry()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description LoadBalancerProperties.Retry.BackoffgetBackoff()intgetMaxRetriesOnNextServiceInstance()intgetMaxRetriesOnSameServiceInstance()Set<Integer>getRetryableStatusCodes()booleanisEnabled()Returns true if the load balancer should retry failed requests.booleanisRetryOnAllOperations()voidsetBackoff(LoadBalancerProperties.Retry.Backoff backoff)voidsetEnabled(boolean enabled)Sets whether the load balancer should retry failed requests.voidsetMaxRetriesOnNextServiceInstance(int maxRetriesOnNextServiceInstance)voidsetMaxRetriesOnSameServiceInstance(int maxRetriesOnSameServiceInstance)voidsetRetryableStatusCodes(Set<Integer> retryableStatusCodes)voidsetRetryOnAllOperations(boolean retryOnAllOperations)
-
-
-
Method Detail
-
isEnabled
public boolean isEnabled()
Returns true if the load balancer should retry failed requests.- Returns:
- True if the load balancer should retry failed requests; false otherwise.
-
setEnabled
public void setEnabled(boolean enabled)
Sets whether the load balancer should retry failed requests.- Parameters:
enabled- Whether the load balancer should retry failed requests.
-
isRetryOnAllOperations
public boolean isRetryOnAllOperations()
-
setRetryOnAllOperations
public void setRetryOnAllOperations(boolean retryOnAllOperations)
-
getMaxRetriesOnSameServiceInstance
public int getMaxRetriesOnSameServiceInstance()
-
setMaxRetriesOnSameServiceInstance
public void setMaxRetriesOnSameServiceInstance(int maxRetriesOnSameServiceInstance)
-
getMaxRetriesOnNextServiceInstance
public int getMaxRetriesOnNextServiceInstance()
-
setMaxRetriesOnNextServiceInstance
public void setMaxRetriesOnNextServiceInstance(int maxRetriesOnNextServiceInstance)
-
getBackoff
public LoadBalancerProperties.Retry.Backoff getBackoff()
-
setBackoff
public void setBackoff(LoadBalancerProperties.Retry.Backoff backoff)
-
-