ThroughputControlGroupConfigBuilder Class
- java.
lang. Object - com.
azure. cosmos. ThroughputControlGroupConfigBuilder
- com.
public class ThroughputControlGroupConfigBuilder
The throughput control group config builder.
Constructor Summary
| Constructor | Description | |
|---|---|---|
| ThroughputControlGroupConfigBuilder() | ||
Method Summary
Methods inherited from java.lang.Object
Constructor Details
ThroughputControlGroupConfigBuilder
public ThroughputControlGroupConfigBuilder()
Method Details
build
public ThroughputControlGroupConfig build()
Validate the throughput configuration and create a new throughput control group config item.
Returns:
continueOnInitError
public ThroughputControlGroupConfigBuilder continueOnInitError(boolean continueOnInitError)
Set whether allow request to continue on original request flow if throughput control controller failed on initialization. If set to true, requests will be able to fall back to original request flow if throughput control controller failed on initialization.
Parameters:
Returns:
defaultControlGroup
public ThroughputControlGroupConfigBuilder defaultControlGroup(boolean aDefault)
Set whether this throughput control group will be used by default. If set to true, requests without explicit override of the throughput control group will be routed to this group.
Parameters:
Returns:
groupName
public ThroughputControlGroupConfigBuilder groupName(String groupName)
Set the throughput control group name.
Parameters:
Returns:
priorityLevel
public ThroughputControlGroupConfigBuilder priorityLevel(PriorityLevel priorityLevel)
Set the throughput control group priority level. The priority level is used to determine which requests will be throttled first when the total throughput of all control groups exceeds the max throughput. By Default PriorityLevel for each request is treated as High. It can be explicitly set to Low for some requests. Priority based execution is currently in preview. To enable the feature, please follow the instructions here
Parameters:
Returns:
setDefault
@Deprecated
public ThroughputControlGroupConfigBuilder setDefault(boolean aDefault)
Set whether this throughput control group will be used by default. If set to true, requests without explicit override of the throughput control group will be routed to this group.
Parameters:
Returns:
setGroupName
@Deprecated
public ThroughputControlGroupConfigBuilder setGroupName(String groupName)
Set the throughput control group name.
Parameters:
Returns:
setTargetThroughput
@Deprecated
public ThroughputControlGroupConfigBuilder setTargetThroughput(int targetThroughput)
Set the throughput control group target throughput. The target throughput value should be greater than 0.
Parameters:
Returns:
setTargetThroughputThreshold
@Deprecated
public ThroughputControlGroupConfigBuilder setTargetThroughputThreshold(double targetThroughputThreshold)
Set the throughput control group target throughput threshold. The target throughput threshold value should be between (0, 1].
Parameters:
Returns:
targetThroughput
public ThroughputControlGroupConfigBuilder targetThroughput(int targetThroughput)
Set the throughput control group target throughput. The target throughput value should be greater than 0.
Parameters:
Returns:
targetThroughputThreshold
public ThroughputControlGroupConfigBuilder targetThroughputThreshold(double targetThroughputThreshold)
Set the throughput control group target throughput threshold. The target throughput threshold value should be between (0, 1].
Parameters:
Returns:
throughputBucket
public ThroughputControlGroupConfigBuilder throughputBucket(int throughputBucket)
Set the throughput bucket of the group.
For more information about throughput bucket please visit Throughput buckets in Azure Cosmos DB
Parameters:
Returns: