public static class AsyncRequestClient.Builder
extends java.lang.Object
Modifier and Type | Method and Description |
---|---|
AsyncRequestClient |
build()
Build an UrbanAirshipClient object.
|
AsyncRequestClient.Builder |
setBaseUri(java.lang.String URI)
Set the base URI -- defaults to "https://go.urbanairship.com"
|
AsyncRequestClient.Builder |
setClientConfigBuilder(DefaultAsyncHttpClientConfig.Builder clientConfigBuilder)
Set the client config builder -- defaults to a new builder.
|
AsyncRequestClient.Builder |
setMaxRetries(java.lang.Integer maxRetries)
Set the maximum for non-POST request retries on 5xxs -- defaults to 10.
|
AsyncRequestClient.Builder |
setProxyServer(ProxyServer proxyServer)
Set the proxy server builder.
|
AsyncRequestClient.Builder |
setRetryPredicate(java.util.function.Predicate<FilterContext> retryPredicate)
Set an optional predicate for allowing request retries on 5xxs.
|
public AsyncRequestClient.Builder setBaseUri(java.lang.String URI)
URI
- String base URIpublic AsyncRequestClient.Builder setMaxRetries(java.lang.Integer maxRetries)
maxRetries
- The maximum.public AsyncRequestClient.Builder setClientConfigBuilder(DefaultAsyncHttpClientConfig.Builder clientConfigBuilder)
clientConfigBuilder
- The client config builder.public AsyncRequestClient.Builder setProxyServer(ProxyServer proxyServer)
proxyServer
- ProxyServerpublic AsyncRequestClient.Builder setRetryPredicate(java.util.function.Predicate<FilterContext> retryPredicate)
retryPredicate
- The retry predicate.public AsyncRequestClient build()
1. App key must be set. 2. App secret must be set. 3. The base URI has been overridden but not set. 4. Max for non-POST 5xx retries must be set, already defaults to 10. 5. HTTP client config builder must be set, already defaults to a new builder.