Class PutClusterCapacityProvidersRequest
- java.lang.Object
-
- software.amazon.awssdk.core.SdkRequest
-
- software.amazon.awssdk.awscore.AwsRequest
-
- software.amazon.awssdk.services.ecs.model.EcsRequest
-
- software.amazon.awssdk.services.ecs.model.PutClusterCapacityProvidersRequest
-
- All Implemented Interfaces:
SdkPojo,ToCopyableBuilder<PutClusterCapacityProvidersRequest.Builder,PutClusterCapacityProvidersRequest>
@Generated("software.amazon.awssdk:codegen") public final class PutClusterCapacityProvidersRequest extends EcsRequest implements ToCopyableBuilder<PutClusterCapacityProvidersRequest.Builder,PutClusterCapacityProvidersRequest>
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfacePutClusterCapacityProvidersRequest.Builder
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static PutClusterCapacityProvidersRequest.Builderbuilder()List<String>capacityProviders()The name of one or more capacity providers to associate with the cluster.Stringcluster()The short name or full Amazon Resource Name (ARN) of the cluster to modify the capacity provider settings for.List<CapacityProviderStrategyItem>defaultCapacityProviderStrategy()The capacity provider strategy to use by default for the cluster.booleanequals(Object obj)booleanequalsBySdkFields(Object obj)<T> Optional<T>getValueForField(String fieldName, Class<T> clazz)booleanhasCapacityProviders()For responses, this returns true if the service returned a value for the CapacityProviders property.booleanhasDefaultCapacityProviderStrategy()For responses, this returns true if the service returned a value for the DefaultCapacityProviderStrategy property.inthashCode()Map<String,SdkField<?>>sdkFieldNameToField()List<SdkField<?>>sdkFields()static Class<? extends PutClusterCapacityProvidersRequest.Builder>serializableBuilderClass()PutClusterCapacityProvidersRequest.BuildertoBuilder()StringtoString()Returns a string representation of this object.-
Methods inherited from class software.amazon.awssdk.awscore.AwsRequest
overrideConfiguration
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface software.amazon.awssdk.utils.builder.ToCopyableBuilder
copy
-
-
-
-
Method Detail
-
cluster
public final String cluster()
The short name or full Amazon Resource Name (ARN) of the cluster to modify the capacity provider settings for. If you don't specify a cluster, the default cluster is assumed.
- Returns:
- The short name or full Amazon Resource Name (ARN) of the cluster to modify the capacity provider settings for. If you don't specify a cluster, the default cluster is assumed.
-
hasCapacityProviders
public final boolean hasCapacityProviders()
For responses, this returns true if the service returned a value for the CapacityProviders property. This DOES NOT check that the value is non-empty (for which, you should check theisEmpty()method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
-
capacityProviders
public final List<String> capacityProviders()
The name of one or more capacity providers to associate with the cluster.
If specifying a capacity provider that uses an Auto Scaling group, the capacity provider must already be created. New capacity providers can be created with the CreateCapacityProvider API operation.
To use a Fargate capacity provider, specify either the
FARGATEorFARGATE_SPOTcapacity providers. The Fargate capacity providers are available to all accounts and only need to be associated with a cluster to be used.Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the
hasCapacityProviders()method.- Returns:
- The name of one or more capacity providers to associate with the cluster.
If specifying a capacity provider that uses an Auto Scaling group, the capacity provider must already be created. New capacity providers can be created with the CreateCapacityProvider API operation.
To use a Fargate capacity provider, specify either the
FARGATEorFARGATE_SPOTcapacity providers. The Fargate capacity providers are available to all accounts and only need to be associated with a cluster to be used.
-
hasDefaultCapacityProviderStrategy
public final boolean hasDefaultCapacityProviderStrategy()
For responses, this returns true if the service returned a value for the DefaultCapacityProviderStrategy property. This DOES NOT check that the value is non-empty (for which, you should check theisEmpty()method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
-
defaultCapacityProviderStrategy
public final List<CapacityProviderStrategyItem> defaultCapacityProviderStrategy()
The capacity provider strategy to use by default for the cluster.
When creating a service or running a task on a cluster, if no capacity provider or launch type is specified then the default capacity provider strategy for the cluster is used.
A capacity provider strategy consists of one or more capacity providers along with the
baseandweightto assign to them. A capacity provider must be associated with the cluster to be used in a capacity provider strategy. The PutClusterCapacityProviders API is used to associate a capacity provider with a cluster. Only capacity providers with anACTIVEorUPDATINGstatus can be used.If specifying a capacity provider that uses an Auto Scaling group, the capacity provider must already be created. New capacity providers can be created with the CreateCapacityProvider API operation.
To use a Fargate capacity provider, specify either the
FARGATEorFARGATE_SPOTcapacity providers. The Fargate capacity providers are available to all accounts and only need to be associated with a cluster to be used.Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the
hasDefaultCapacityProviderStrategy()method.- Returns:
- The capacity provider strategy to use by default for the cluster.
When creating a service or running a task on a cluster, if no capacity provider or launch type is specified then the default capacity provider strategy for the cluster is used.
A capacity provider strategy consists of one or more capacity providers along with the
baseandweightto assign to them. A capacity provider must be associated with the cluster to be used in a capacity provider strategy. The PutClusterCapacityProviders API is used to associate a capacity provider with a cluster. Only capacity providers with anACTIVEorUPDATINGstatus can be used.If specifying a capacity provider that uses an Auto Scaling group, the capacity provider must already be created. New capacity providers can be created with the CreateCapacityProvider API operation.
To use a Fargate capacity provider, specify either the
FARGATEorFARGATE_SPOTcapacity providers. The Fargate capacity providers are available to all accounts and only need to be associated with a cluster to be used.
-
toBuilder
public PutClusterCapacityProvidersRequest.Builder toBuilder()
- Specified by:
toBuilderin interfaceToCopyableBuilder<PutClusterCapacityProvidersRequest.Builder,PutClusterCapacityProvidersRequest>- Specified by:
toBuilderin classEcsRequest
-
builder
public static PutClusterCapacityProvidersRequest.Builder builder()
-
serializableBuilderClass
public static Class<? extends PutClusterCapacityProvidersRequest.Builder> serializableBuilderClass()
-
hashCode
public final int hashCode()
- Overrides:
hashCodein classAwsRequest
-
equals
public final boolean equals(Object obj)
- Overrides:
equalsin classAwsRequest
-
equalsBySdkFields
public final boolean equalsBySdkFields(Object obj)
- Specified by:
equalsBySdkFieldsin interfaceSdkPojo
-
toString
public final String toString()
Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value.
-
getValueForField
public final <T> Optional<T> getValueForField(String fieldName, Class<T> clazz)
- Overrides:
getValueForFieldin classSdkRequest
-
sdkFieldNameToField
public final Map<String,SdkField<?>> sdkFieldNameToField()
- Specified by:
sdkFieldNameToFieldin interfaceSdkPojo
-
-