retryOptions.setMaxRetryAttemptsOnThrottledRequests(this.getIntProperty( "azurecosmos.maxRetryAttemptsOnThrottledRequests", retryOptions.getMaxRetryAttemptsOnThrottledRequests())); retryOptions.setMaxRetryWaitTimeInSeconds(this.getIntProperty( "azurecosmos.maxRetryWaitTimeInSeconds", connectionPolicy.getConnectionMode(), consistencyLevel.toString(), connectionPolicy.getRetryOptions().getMaxRetryAttemptsOnThrottledRequests(), connectionPolicy.getRetryOptions().getMaxRetryWaitTimeInSeconds(), this.useSinglePartitionCollection,
/** * Gets the maximum number of retries in the case where the request fails * due to a throttle error. * <p> * This property is deprecated. Please use * connectionPolicy.getRetryOptions().getMaxRetryAttemptsOnThrottledRequests() for equivalent * functionality. * * @return maximum number of retry attempts. */ @Deprecated public Integer getMaxRetryOnThrottledAttempts() { return this.retryOptions.getMaxRetryAttemptsOnThrottledRequests(); }
public ExecuteDocumentClientRequestRetryHandler(RxDocumentServiceRequest request, EndpointManager globalEndpointManager, AsyncDocumentClient client) { this.discoveryRetryPolicy = RetryPolicyBridgeInternal.createEndpointDiscoveryRetryPolicy( client.getConnectionPolicy(), globalEndpointManager); this.throttleRetryPolicy = RetryPolicyBridgeInternal.createResourceThrottleRetryPolicy( client.getConnectionPolicy().getRetryOptions().getMaxRetryAttemptsOnThrottledRequests(), client.getConnectionPolicy().getRetryOptions().getMaxRetryWaitTimeInSeconds()); this.sessionReadRetryPolicy = RetryPolicyBridgeInternal.createSessionReadRetryPolicy( globalEndpointManager, request); }