public static final class CfnEC2Fleet.OnDemandOptionsRequestProperty.Builder
extends java.lang.Object
CfnEC2Fleet.OnDemandOptionsRequestProperty
Constructor and Description |
---|
Builder() |
public CfnEC2Fleet.OnDemandOptionsRequestProperty.Builder allocationStrategy(java.lang.String allocationStrategy)
CfnEC2Fleet.OnDemandOptionsRequestProperty.getAllocationStrategy()
allocationStrategy
- The strategy that determines the order of the launch template overrides to use in fulfilling On-Demand capacity.
lowest-price
- EC2 Fleet uses price to determine the order, launching the lowest price first.
prioritized
- EC2 Fleet uses the priority that you assigned to each launch template override, launching the highest priority first.
Default: lowest-price
this
public CfnEC2Fleet.OnDemandOptionsRequestProperty.Builder capacityReservationOptions(IResolvable capacityReservationOptions)
capacityReservationOptions
- The strategy for using unused Capacity Reservations for fulfilling On-Demand capacity.
Supported only for fleets of type instant
.this
public CfnEC2Fleet.OnDemandOptionsRequestProperty.Builder capacityReservationOptions(CfnEC2Fleet.CapacityReservationOptionsRequestProperty capacityReservationOptions)
capacityReservationOptions
- The strategy for using unused Capacity Reservations for fulfilling On-Demand capacity.
Supported only for fleets of type instant
.this
public CfnEC2Fleet.OnDemandOptionsRequestProperty.Builder maxTotalPrice(java.lang.String maxTotalPrice)
CfnEC2Fleet.OnDemandOptionsRequestProperty.getMaxTotalPrice()
maxTotalPrice
- The maximum amount per hour for On-Demand Instances that you're willing to pay.this
public CfnEC2Fleet.OnDemandOptionsRequestProperty.Builder minTargetCapacity(java.lang.Number minTargetCapacity)
CfnEC2Fleet.OnDemandOptionsRequestProperty.getMinTargetCapacity()
minTargetCapacity
- The minimum target capacity for On-Demand Instances in the fleet.
If the minimum target capacity is not reached, the fleet launches no instances.
Supported only for fleets of type instant
.
At least one of the following must be specified: SingleAvailabilityZone
| SingleInstanceType
this
public CfnEC2Fleet.OnDemandOptionsRequestProperty.Builder singleAvailabilityZone(java.lang.Boolean singleAvailabilityZone)
CfnEC2Fleet.OnDemandOptionsRequestProperty.getSingleAvailabilityZone()
singleAvailabilityZone
- Indicates that the fleet launches all On-Demand Instances into a single Availability Zone.
Supported only for fleets of type instant
.this
public CfnEC2Fleet.OnDemandOptionsRequestProperty.Builder singleAvailabilityZone(IResolvable singleAvailabilityZone)
CfnEC2Fleet.OnDemandOptionsRequestProperty.getSingleAvailabilityZone()
singleAvailabilityZone
- Indicates that the fleet launches all On-Demand Instances into a single Availability Zone.
Supported only for fleets of type instant
.this
public CfnEC2Fleet.OnDemandOptionsRequestProperty.Builder singleInstanceType(java.lang.Boolean singleInstanceType)
CfnEC2Fleet.OnDemandOptionsRequestProperty.getSingleInstanceType()
singleInstanceType
- Indicates that the fleet uses a single instance type to launch all On-Demand Instances in the fleet.
Supported only for fleets of type instant
.this
public CfnEC2Fleet.OnDemandOptionsRequestProperty.Builder singleInstanceType(IResolvable singleInstanceType)
CfnEC2Fleet.OnDemandOptionsRequestProperty.getSingleInstanceType()
singleInstanceType
- Indicates that the fleet uses a single instance type to launch all On-Demand Instances in the fleet.
Supported only for fleets of type instant
.this
public CfnEC2Fleet.OnDemandOptionsRequestProperty build()
CfnEC2Fleet.OnDemandOptionsRequestProperty
java.lang.NullPointerException
- if any required attribute was not provided