public class SpotMixedAllocationPolicy extends AbstractModel
Constructor and Description |
---|
SpotMixedAllocationPolicy() |
SpotMixedAllocationPolicy(SpotMixedAllocationPolicy source)
NOTE: Any ambiguous key set via .set("AnyKey", "value") will be a shallow copy,
and any explicit key, i.e Foo, set via .setFoo("value") will be a deep copy.
|
Modifier and Type | Method and Description |
---|---|
Long |
getBaseCapacity()
Get The minimum number of the scaling group’s capacity that must be fulfilled by pay-as-you-go instances.
|
Boolean |
getCompensateWithBaseInstance()
Get Whether to replace with pay-as-you go instances.
|
Long |
getOnDemandPercentageAboveBaseCapacity()
Get Controls the percentage of pay-as-you-go instances for the additional capacity beyond `BaseCapacity`.
|
String |
getSpotAllocationStrategy()
Get Specifies how to assign spot instances in a mixed instance mode.
|
void |
setBaseCapacity(Long BaseCapacity)
Set The minimum number of the scaling group’s capacity that must be fulfilled by pay-as-you-go instances.
|
void |
setCompensateWithBaseInstance(Boolean CompensateWithBaseInstance)
Set Whether to replace with pay-as-you go instances.
|
void |
setOnDemandPercentageAboveBaseCapacity(Long OnDemandPercentageAboveBaseCapacity)
Set Controls the percentage of pay-as-you-go instances for the additional capacity beyond `BaseCapacity`.
|
void |
setSpotAllocationStrategy(String SpotAllocationStrategy)
Set Specifies how to assign spot instances in a mixed instance mode.
|
void |
toMap(HashMap<String,String> map,
String prefix)
Internal implementation, normal users should not use it.
|
any, fromJsonString, getBinaryParams, getMultipartRequestParams, set, setParamArrayObj, setParamArraySimple, setParamObj, setParamSimple, toJsonString
public SpotMixedAllocationPolicy()
public SpotMixedAllocationPolicy(SpotMixedAllocationPolicy source)
public Long getBaseCapacity()
public void setBaseCapacity(Long BaseCapacity)
BaseCapacity
- The minimum number of the scaling group’s capacity that must be fulfilled by pay-as-you-go instances. It defaults to 0 if not specified. Its value cannot exceed the max capacity of the scaling group.
Note: this field may return `null`, indicating that no valid value can be obtained.public Long getOnDemandPercentageAboveBaseCapacity()
public void setOnDemandPercentageAboveBaseCapacity(Long OnDemandPercentageAboveBaseCapacity)
OnDemandPercentageAboveBaseCapacity
- Controls the percentage of pay-as-you-go instances for the additional capacity beyond `BaseCapacity`. Valid range: 0-100. The value 0 indicates that only spot instances are provisioned, while the value 100 indicates that only pay-as-you-go instances are provisioned. It defaults to 70 if not specified. The number of pay-as-you-go instances calculated on the percentage should be rounded up.
For example, if the desired capacity is 3, the `BaseCapacity` is set to 1, and the `OnDemandPercentageAboveBaseCapacity` is set to 1, the scaling group will have 2 pay-as-you-go instance (one comes from the base capacity, and the other comes from the rounded up value of the proportion), and 1 spot instance.
Note: this field may return `null`, indicating that no valid value can be obtained.public String getSpotAllocationStrategy()
public void setSpotAllocationStrategy(String SpotAllocationStrategy)
SpotAllocationStrategy
- Specifies how to assign spot instances in a mixed instance mode. Valid values: `COST_OPTIMIZED` and `CAPACITY_OPTIMIZED`; default value: `COST_OPTIMIZED`.
public Boolean getCompensateWithBaseInstance()
public void setCompensateWithBaseInstance(Boolean CompensateWithBaseInstance)
CompensateWithBaseInstance
- Whether to replace with pay-as-you go instances. Valid values:
Copyright © 2023. All rights reserved.