Class AutoScalingGroup
- All Implemented Interfaces:
Serializable
,SdkPojo
,ToCopyableBuilder<AutoScalingGroup.Builder,
AutoScalingGroup>
Describes an Auto Scaling group.
- See Also:
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionfinal String
The Amazon Resource Name (ARN) of the Auto Scaling group.final String
The name of the Auto Scaling group.One or more Availability Zones for the group.static AutoScalingGroup.Builder
builder()
final Boolean
Indicates whether Capacity Rebalancing is enabled.final String
context()
Reserved.final Instant
The date and time the group was created.final Integer
The duration of the default cooldown period, in seconds.final Integer
The duration of the default instance warmup, in seconds.final Integer
The desired size of the group.final String
The unit of measurement for the value specified for desired capacity.final List
<EnabledMetric> The metrics enabled for the group.final boolean
final boolean
equalsBySdkFields
(Object obj) Indicates whether some other object is "equal to" this one by SDK fields.final <T> Optional
<T> getValueForField
(String fieldName, Class<T> clazz) final boolean
For responses, this returns true if the service returned a value for the AvailabilityZones property.final boolean
For responses, this returns true if the service returned a value for the EnabledMetrics property.final int
hashCode()
final boolean
For responses, this returns true if the service returned a value for the Instances property.final boolean
For responses, this returns true if the service returned a value for the LoadBalancerNames property.final boolean
For responses, this returns true if the service returned a value for the SuspendedProcesses property.final boolean
hasTags()
For responses, this returns true if the service returned a value for the Tags property.final boolean
For responses, this returns true if the service returned a value for the TargetGroupARNs property.final boolean
For responses, this returns true if the service returned a value for the TerminationPolicies property.final boolean
For responses, this returns true if the service returned a value for the TrafficSources property.final Integer
The duration of the health check grace period, in seconds.final String
A comma-separated value string of one or more health check types.The EC2 instances associated with the group.final String
The name of the associated launch configuration.The launch template for the group.One or more load balancers associated with the group.final Integer
The maximum amount of time, in seconds, that an instance can be in service.final Integer
maxSize()
The maximum size of the group.final Integer
minSize()
The minimum size of the group.final MixedInstancesPolicy
The mixed instances policy for the group.final Boolean
Indicates whether newly launched instances are protected from termination by Amazon EC2 Auto Scaling when scaling in.final String
The name of the placement group into which to launch your instances, if any.final Integer
The predicted capacity of the group when it has a predictive scaling policy.static Class
<? extends AutoScalingGroup.Builder> final String
The Amazon Resource Name (ARN) of the service-linked role that the Auto Scaling group uses to call other Amazon Web Services on your behalf.final String
status()
The current state of the group when the DeleteAutoScalingGroup operation is in progress.final List
<SuspendedProcess> The suspended processes associated with the group.final List
<TagDescription> tags()
The tags for the group.The Amazon Resource Names (ARN) of the target groups for your load balancer.The termination policies for the group.Take this object and create a builder that contains all of the current property values of this object.final String
toString()
Returns a string representation of this object.final List
<TrafficSourceIdentifier> The traffic sources associated with this Auto Scaling group.final String
One or more subnet IDs, if applicable, separated by commas.final WarmPoolConfiguration
The warm pool for the group.final Integer
The current size of the warm pool.Methods inherited from interface software.amazon.awssdk.utils.builder.ToCopyableBuilder
copy
-
Method Details
-
autoScalingGroupName
The name of the Auto Scaling group.
- Returns:
- The name of the Auto Scaling group.
-
autoScalingGroupARN
The Amazon Resource Name (ARN) of the Auto Scaling group.
- Returns:
- The Amazon Resource Name (ARN) of the Auto Scaling group.
-
launchConfigurationName
The name of the associated launch configuration.
- Returns:
- The name of the associated launch configuration.
-
launchTemplate
The launch template for the group.
- Returns:
- The launch template for the group.
-
mixedInstancesPolicy
The mixed instances policy for the group.
- Returns:
- The mixed instances policy for the group.
-
minSize
The minimum size of the group.
- Returns:
- The minimum size of the group.
-
maxSize
The maximum size of the group.
- Returns:
- The maximum size of the group.
-
desiredCapacity
The desired size of the group.
- Returns:
- The desired size of the group.
-
predictedCapacity
The predicted capacity of the group when it has a predictive scaling policy.
- Returns:
- The predicted capacity of the group when it has a predictive scaling policy.
-
defaultCooldown
The duration of the default cooldown period, in seconds.
- Returns:
- The duration of the default cooldown period, in seconds.
-
hasAvailabilityZones
public final boolean hasAvailabilityZones()For responses, this returns true if the service returned a value for the AvailabilityZones 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. -
availabilityZones
One or more Availability Zones for the group.
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
hasAvailabilityZones()
method.- Returns:
- One or more Availability Zones for the group.
-
hasLoadBalancerNames
public final boolean hasLoadBalancerNames()For responses, this returns true if the service returned a value for the LoadBalancerNames 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. -
loadBalancerNames
One or more load balancers associated with the group.
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
hasLoadBalancerNames()
method.- Returns:
- One or more load balancers associated with the group.
-
hasTargetGroupARNs
public final boolean hasTargetGroupARNs()For responses, this returns true if the service returned a value for the TargetGroupARNs 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. -
targetGroupARNs
The Amazon Resource Names (ARN) of the target groups for your load balancer.
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
hasTargetGroupARNs()
method.- Returns:
- The Amazon Resource Names (ARN) of the target groups for your load balancer.
-
healthCheckType
A comma-separated value string of one or more health check types.
- Returns:
- A comma-separated value string of one or more health check types.
-
healthCheckGracePeriod
The duration of the health check grace period, in seconds.
- Returns:
- The duration of the health check grace period, in seconds.
-
hasInstances
public final boolean hasInstances()For responses, this returns true if the service returned a value for the Instances 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. -
instances
The EC2 instances associated with the group.
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
hasInstances()
method.- Returns:
- The EC2 instances associated with the group.
-
createdTime
The date and time the group was created.
- Returns:
- The date and time the group was created.
-
hasSuspendedProcesses
public final boolean hasSuspendedProcesses()For responses, this returns true if the service returned a value for the SuspendedProcesses 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. -
suspendedProcesses
The suspended processes associated with the group.
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
hasSuspendedProcesses()
method.- Returns:
- The suspended processes associated with the group.
-
placementGroup
The name of the placement group into which to launch your instances, if any.
- Returns:
- The name of the placement group into which to launch your instances, if any.
-
vpcZoneIdentifier
One or more subnet IDs, if applicable, separated by commas.
- Returns:
- One or more subnet IDs, if applicable, separated by commas.
-
hasEnabledMetrics
public final boolean hasEnabledMetrics()For responses, this returns true if the service returned a value for the EnabledMetrics 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. -
enabledMetrics
The metrics enabled for the group.
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
hasEnabledMetrics()
method.- Returns:
- The metrics enabled for the group.
-
status
The current state of the group when the DeleteAutoScalingGroup operation is in progress.
- Returns:
- The current state of the group when the DeleteAutoScalingGroup operation is in progress.
-
hasTags
public final boolean hasTags()For responses, this returns true if the service returned a value for the Tags 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. -
tags
The tags for the group.
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
hasTags()
method.- Returns:
- The tags for the group.
-
hasTerminationPolicies
public final boolean hasTerminationPolicies()For responses, this returns true if the service returned a value for the TerminationPolicies 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. -
terminationPolicies
The termination policies for the group.
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
hasTerminationPolicies()
method.- Returns:
- The termination policies for the group.
-
newInstancesProtectedFromScaleIn
Indicates whether newly launched instances are protected from termination by Amazon EC2 Auto Scaling when scaling in.
- Returns:
- Indicates whether newly launched instances are protected from termination by Amazon EC2 Auto Scaling when scaling in.
-
serviceLinkedRoleARN
The Amazon Resource Name (ARN) of the service-linked role that the Auto Scaling group uses to call other Amazon Web Services on your behalf.
- Returns:
- The Amazon Resource Name (ARN) of the service-linked role that the Auto Scaling group uses to call other Amazon Web Services on your behalf.
-
maxInstanceLifetime
The maximum amount of time, in seconds, that an instance can be in service.
Valid Range: Minimum value of 0.
- Returns:
- The maximum amount of time, in seconds, that an instance can be in service.
Valid Range: Minimum value of 0.
-
capacityRebalance
Indicates whether Capacity Rebalancing is enabled.
- Returns:
- Indicates whether Capacity Rebalancing is enabled.
-
warmPoolConfiguration
The warm pool for the group.
- Returns:
- The warm pool for the group.
-
warmPoolSize
The current size of the warm pool.
- Returns:
- The current size of the warm pool.
-
context
Reserved.
- Returns:
- Reserved.
-
desiredCapacityType
The unit of measurement for the value specified for desired capacity. Amazon EC2 Auto Scaling supports
DesiredCapacityType
for attribute-based instance type selection only.- Returns:
- The unit of measurement for the value specified for desired capacity. Amazon EC2 Auto Scaling supports
DesiredCapacityType
for attribute-based instance type selection only.
-
defaultInstanceWarmup
The duration of the default instance warmup, in seconds.
- Returns:
- The duration of the default instance warmup, in seconds.
-
hasTrafficSources
public final boolean hasTrafficSources()For responses, this returns true if the service returned a value for the TrafficSources 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. -
trafficSources
The traffic sources associated with this Auto Scaling group.
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
hasTrafficSources()
method.- Returns:
- The traffic sources associated with this Auto Scaling group.
-
toBuilder
Description copied from interface:ToCopyableBuilder
Take this object and create a builder that contains all of the current property values of this object.- Specified by:
toBuilder
in interfaceToCopyableBuilder<AutoScalingGroup.Builder,
AutoScalingGroup> - Returns:
- a builder for type T
-
builder
-
serializableBuilderClass
-
hashCode
public final int hashCode() -
equals
-
equalsBySdkFields
Description copied from interface:SdkPojo
Indicates whether some other object is "equal to" this one by SDK fields. An SDK field is a modeled, non-inherited field in anSdkPojo
class, and is generated based on a service model.If an
SdkPojo
class does not have any inherited fields,equalsBySdkFields
andequals
are essentially the same.- Specified by:
equalsBySdkFields
in interfaceSdkPojo
- Parameters:
obj
- the object to be compared with- Returns:
- true if the other object equals to this object by sdk fields, false otherwise.
-
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
-
sdkFields
-