public static final class SplitClientConfig.Builder extends Object
| Constructor and Description |
|---|
Builder() |
| Modifier and Type | Method and Description |
|---|---|
SplitClientConfig |
build() |
SplitClientConfig.Builder |
connectionTimeout(int ms) |
SplitClientConfig.Builder |
connectionTimeoutInMs(int ms)
Deprecated.
|
SplitClientConfig.Builder |
enableDebug() |
SplitClientConfig.Builder |
endpoint(String endpoint)
The rest endpoint that sdk will hit for latest features and segments.
|
SplitClientConfig.Builder |
eventsEndpoint(String eventsEndpoint)
The rest endpoint that sdk will hit for impressions and metrics.
|
SplitClientConfig.Builder |
featuresRefreshRate(int seconds)
The SDK will poll the endpoint for changes to features at this period.
|
SplitClientConfig.Builder |
impressionsRefreshRate(int seconds)
The treatment log captures the which key saw what treatment ("on", "off", etc)
at what time.
|
SplitClientConfig.Builder |
metricsRefreshRate(int seconds)
The diagnostic metrics collected by the SDK are pushed back to split endpoint
at this period.
|
SplitClientConfig.Builder |
numThreadsForSegmentFetch(int numThreads)
Deprecated.
|
SplitClientConfig.Builder |
pollForFeatureChangesEveryNSeconds(int n)
Deprecated.
|
SplitClientConfig.Builder |
pollForSegmentChangesEveryNSeconds(int n)
Deprecated.
|
SplitClientConfig.Builder |
readTimeout(int ms) |
SplitClientConfig.Builder |
readTimeoutInMs(int ms)
Deprecated.
|
SplitClientConfig.Builder |
ready(int milliseconds)
The SDK kicks off background threads to download data necessary
for using the SDK.
|
SplitClientConfig.Builder |
segmentsRefreshRate(int seconds)
The SDK will poll the endpoint for changes to segments at this period in seconds.
|
SplitClientConfig.Builder |
treatmentLogCacheExpireNSecondsAfterWrite(int n)
Deprecated.
|
public SplitClientConfig.Builder endpoint(String endpoint)
endpoint - MUST NOT be nullpublic SplitClientConfig.Builder eventsEndpoint(String eventsEndpoint)
eventsEndpoint - MUST NOT be null@Deprecated public SplitClientConfig.Builder pollForFeatureChangesEveryNSeconds(int n)
Implementation Note: The SDK actually polls at a random interval chosen between (0.5 * n, n). This is to ensure that SDKs that are deployed simultaneously on different machines do not inundate the backend with requests at the same interval.
n - MUST be greater than 0. Default value is 60.public SplitClientConfig.Builder featuresRefreshRate(int seconds)
Implementation Note: The SDK actually polls at a random interval chosen between (0.5 * n, n). This is to ensure that SDKs that are deployed simultaneously on different machines do not inundate the backend with requests at the same interval.
seconds - MUST be greater than 0. Default value is 60.@Deprecated public SplitClientConfig.Builder pollForSegmentChangesEveryNSeconds(int n)
Implementation Note: The SDK actually polls at a random interval chosen between (0.5 * n, n). This is to ensure that SDKs that are deployed simultaneously on different machines do not inundate the backend with requests at the same interval.
n - MUST be greater than 0. Default value is 60.public SplitClientConfig.Builder segmentsRefreshRate(int seconds)
Implementation Note: The SDK actually polls at a random interval chosen between (0.5 * n, n). This is to ensure that SDKs that are deployed simultaneously on different machines do not inundate the backend with requests at the same interval.
seconds - MUST be greater than 0. Default value is 60.@Deprecated public SplitClientConfig.Builder treatmentLogCacheExpireNSecondsAfterWrite(int n)
n - MUST be > 0.public SplitClientConfig.Builder impressionsRefreshRate(int seconds)
seconds - MUST be > 0.public SplitClientConfig.Builder metricsRefreshRate(int seconds)
seconds - MUST be > 0.@Deprecated public SplitClientConfig.Builder connectionTimeoutInMs(int ms)
ms - MUST be greater than 0.public SplitClientConfig.Builder connectionTimeout(int ms)
@Deprecated public SplitClientConfig.Builder readTimeoutInMs(int ms)
ms - MUST be greater than 0.public SplitClientConfig.Builder readTimeout(int ms)
public SplitClientConfig.Builder enableDebug()
@Deprecated public SplitClientConfig.Builder numThreadsForSegmentFetch(int numThreads)
numThreads - MUST BE greater than 0;public SplitClientConfig.Builder ready(int milliseconds)
If this parameter is set to a non-negative value, the SDK will block for that number of milliseconds for the data to be downloaded.
If the download is not successful in this time period, a TimeOutException will be thrown.
A negative value implies that the SDK building MUST NOT block. In this scenario, the SDK might return the 'control' treatment until the desired data has been downloaded.
milliseconds - MUST BE greater than or equal to 0;public SplitClientConfig build()
Copyright © 2016. All rights reserved.