Interface GetSpotPlacementScoresRequest.Builder
-
- All Superinterfaces:
AwsRequest.Builder
,Buildable
,CopyableBuilder<GetSpotPlacementScoresRequest.Builder,GetSpotPlacementScoresRequest>
,Ec2Request.Builder
,SdkBuilder<GetSpotPlacementScoresRequest.Builder,GetSpotPlacementScoresRequest>
,SdkPojo
,SdkRequest.Builder
- Enclosing class:
- GetSpotPlacementScoresRequest
public static interface GetSpotPlacementScoresRequest.Builder extends Ec2Request.Builder, SdkPojo, CopyableBuilder<GetSpotPlacementScoresRequest.Builder,GetSpotPlacementScoresRequest>
-
-
Method Summary
-
Methods inherited from interface software.amazon.awssdk.awscore.AwsRequest.Builder
overrideConfiguration
-
Methods inherited from interface software.amazon.awssdk.utils.builder.CopyableBuilder
copy
-
Methods inherited from interface software.amazon.awssdk.services.ec2.model.Ec2Request.Builder
build
-
Methods inherited from interface software.amazon.awssdk.utils.builder.SdkBuilder
applyMutation, build
-
Methods inherited from interface software.amazon.awssdk.core.SdkPojo
equalsBySdkFields, sdkFields
-
-
-
-
Method Detail
-
instanceTypes
GetSpotPlacementScoresRequest.Builder instanceTypes(Collection<String> instanceTypes)
The instance types. We recommend that you specify at least three instance types. If you specify one or two instance types, or specify variations of a single instance type (for example, an
m3.xlarge
with and without instance storage), the returned placement score will always be low.If you specify
InstanceTypes
, you can't specifyInstanceRequirementsWithMetadata
.- Parameters:
instanceTypes
- The instance types. We recommend that you specify at least three instance types. If you specify one or two instance types, or specify variations of a single instance type (for example, anm3.xlarge
with and without instance storage), the returned placement score will always be low.If you specify
InstanceTypes
, you can't specifyInstanceRequirementsWithMetadata
.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
instanceTypes
GetSpotPlacementScoresRequest.Builder instanceTypes(String... instanceTypes)
The instance types. We recommend that you specify at least three instance types. If you specify one or two instance types, or specify variations of a single instance type (for example, an
m3.xlarge
with and without instance storage), the returned placement score will always be low.If you specify
InstanceTypes
, you can't specifyInstanceRequirementsWithMetadata
.- Parameters:
instanceTypes
- The instance types. We recommend that you specify at least three instance types. If you specify one or two instance types, or specify variations of a single instance type (for example, anm3.xlarge
with and without instance storage), the returned placement score will always be low.If you specify
InstanceTypes
, you can't specifyInstanceRequirementsWithMetadata
.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
targetCapacity
GetSpotPlacementScoresRequest.Builder targetCapacity(Integer targetCapacity)
The target capacity.
- Parameters:
targetCapacity
- The target capacity.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
targetCapacityUnitType
GetSpotPlacementScoresRequest.Builder targetCapacityUnitType(String targetCapacityUnitType)
The unit for the target capacity.
- Parameters:
targetCapacityUnitType
- The unit for the target capacity.- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
TargetCapacityUnitType
,TargetCapacityUnitType
-
targetCapacityUnitType
GetSpotPlacementScoresRequest.Builder targetCapacityUnitType(TargetCapacityUnitType targetCapacityUnitType)
The unit for the target capacity.
- Parameters:
targetCapacityUnitType
- The unit for the target capacity.- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
TargetCapacityUnitType
,TargetCapacityUnitType
-
singleAvailabilityZone
GetSpotPlacementScoresRequest.Builder singleAvailabilityZone(Boolean singleAvailabilityZone)
Specify
true
so that the response returns a list of scored Availability Zones. Otherwise, the response returns a list of scored Regions.A list of scored Availability Zones is useful if you want to launch all of your Spot capacity into a single Availability Zone.
- Parameters:
singleAvailabilityZone
- Specifytrue
so that the response returns a list of scored Availability Zones. Otherwise, the response returns a list of scored Regions.A list of scored Availability Zones is useful if you want to launch all of your Spot capacity into a single Availability Zone.
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
regionNames
GetSpotPlacementScoresRequest.Builder regionNames(Collection<String> regionNames)
The Regions used to narrow down the list of Regions to be scored. Enter the Region code, for example,
us-east-1
.- Parameters:
regionNames
- The Regions used to narrow down the list of Regions to be scored. Enter the Region code, for example,us-east-1
.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
regionNames
GetSpotPlacementScoresRequest.Builder regionNames(String... regionNames)
The Regions used to narrow down the list of Regions to be scored. Enter the Region code, for example,
us-east-1
.- Parameters:
regionNames
- The Regions used to narrow down the list of Regions to be scored. Enter the Region code, for example,us-east-1
.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
instanceRequirementsWithMetadata
GetSpotPlacementScoresRequest.Builder instanceRequirementsWithMetadata(InstanceRequirementsWithMetadataRequest instanceRequirementsWithMetadata)
The attributes for the instance types. When you specify instance attributes, Amazon EC2 will identify instance types with those attributes.
If you specify
InstanceRequirementsWithMetadata
, you can't specifyInstanceTypes
.- Parameters:
instanceRequirementsWithMetadata
- The attributes for the instance types. When you specify instance attributes, Amazon EC2 will identify instance types with those attributes.If you specify
InstanceRequirementsWithMetadata
, you can't specifyInstanceTypes
.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
instanceRequirementsWithMetadata
default GetSpotPlacementScoresRequest.Builder instanceRequirementsWithMetadata(Consumer<InstanceRequirementsWithMetadataRequest.Builder> instanceRequirementsWithMetadata)
The attributes for the instance types. When you specify instance attributes, Amazon EC2 will identify instance types with those attributes.
If you specify
This is a convenience method that creates an instance of theInstanceRequirementsWithMetadata
, you can't specifyInstanceTypes
.InstanceRequirementsWithMetadataRequest.Builder
avoiding the need to create one manually viaInstanceRequirementsWithMetadataRequest.builder()
.When the
Consumer
completes,SdkBuilder.build()
is called immediately and its result is passed toinstanceRequirementsWithMetadata(InstanceRequirementsWithMetadataRequest)
.- Parameters:
instanceRequirementsWithMetadata
- a consumer that will call methods onInstanceRequirementsWithMetadataRequest.Builder
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
instanceRequirementsWithMetadata(InstanceRequirementsWithMetadataRequest)
-
dryRun
GetSpotPlacementScoresRequest.Builder dryRun(Boolean dryRun)
Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is
DryRunOperation
. Otherwise, it isUnauthorizedOperation
.- Parameters:
dryRun
- Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response isDryRunOperation
. Otherwise, it isUnauthorizedOperation
.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
maxResults
GetSpotPlacementScoresRequest.Builder maxResults(Integer maxResults)
The maximum number of items to return for this request. To get the next page of items, make another request with the token returned in the output. For more information, see Pagination.
- Parameters:
maxResults
- The maximum number of items to return for this request. To get the next page of items, make another request with the token returned in the output. For more information, see Pagination.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
nextToken
GetSpotPlacementScoresRequest.Builder nextToken(String nextToken)
The token returned from a previous paginated request. Pagination continues from the end of the items returned by the previous request.
- Parameters:
nextToken
- The token returned from a previous paginated request. Pagination continues from the end of the items returned by the previous request.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
overrideConfiguration
GetSpotPlacementScoresRequest.Builder overrideConfiguration(AwsRequestOverrideConfiguration overrideConfiguration)
- Specified by:
overrideConfiguration
in interfaceAwsRequest.Builder
-
overrideConfiguration
GetSpotPlacementScoresRequest.Builder overrideConfiguration(Consumer<AwsRequestOverrideConfiguration.Builder> builderConsumer)
- Specified by:
overrideConfiguration
in interfaceAwsRequest.Builder
-
-