public static final class SplitClientConfig.Builder extends Object
| Constructor and Description |
|---|
Builder() |
| Modifier and Type | Method and Description |
|---|---|
SplitClientConfig |
build() |
SplitClientConfig.Builder |
connectionTimeoutInMs(int ms)
Http client connection timeout.
|
SplitClientConfig.Builder |
enableDebug() |
SplitClientConfig.Builder |
endpoint(String endpoint)
The rest endpoint that sdk will hit for latest features and segments.
|
SplitClientConfig.Builder |
numThreadsForSegmentFetch(int numThreads)
The SDK fetches segment memberships on a schedule in an
asynchrnonous manner.
|
SplitClientConfig.Builder |
pollForFeatureChangesEveryNSeconds(int n)
The SDK will poll the endpoint for changes to features at this period.
|
SplitClientConfig.Builder |
pollForSegmentChangesEveryNSeconds(int n)
The SDK will poll the endpoint for changes to segments at this period in seconds.
|
SplitClientConfig.Builder |
readTimeoutInMs(int ms)
Http client read timeout.
|
SplitClientConfig.Builder |
treatmentLogCacheExpireNSecondsAfterWrite(int n)
The treatment log captures the which key saw what treatment ("on", "off", etc)
at what time.
|
public SplitClientConfig.Builder endpoint(String endpoint)
endpoint - MUST NOT be nullpublic 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 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 treatmentLogCacheExpireNSecondsAfterWrite(int n)
n - MUST be > 0.public SplitClientConfig.Builder connectionTimeoutInMs(int ms)
ms - MUST be greater than 0.public SplitClientConfig.Builder readTimeoutInMs(int ms)
ms - MUST be greater than 0.public SplitClientConfig.Builder enableDebug()
public SplitClientConfig.Builder numThreadsForSegmentFetch(int numThreads)
numThreads - MUST BE greater than 0;public SplitClientConfig build()
Copyright © 2016. All rights reserved.