Class Stack
- All Implemented Interfaces:
Serializable
,SdkPojo
,ToCopyableBuilder<Stack.Builder,
Stack>
Describes a stack.
- See Also:
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionfinal String
The agent version.final String
arn()
The stack's ARN.final Map
<StackAttributesKeys, String> The stack's attributes.The stack's attributes.static Stack.Builder
builder()
final ChefConfiguration
AChefConfiguration
object that specifies whether to enable Berkshelf and the Berkshelf version.The configuration manager.final String
The date when the stack was created.final Source
Contains the information required to retrieve an app or cookbook from a repository.final String
A JSON object that contains user-defined attributes to be added to the stack configuration and deployment attributes.final String
The stack's default Availability Zone.final String
The ARN of an IAM profile that is the default profile for all of the stack's EC2 instances.final String
The stack's default operating system.final RootDeviceType
The default root device type.final String
The default root device type.final String
A default Amazon EC2 key pair for the stack's instances.final String
The default subnet ID; applicable only if the stack is running in a VPC.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 Attributes property.final int
hashCode()
final String
The stack host name theme, with spaces replaced by underscores.final String
name()
The stack name.final String
region()
The stack Amazon Web Services Region, such asap-northeast-2
.static Class
<? extends Stack.Builder> final String
The stack Identity and Access Management (IAM) role.final String
stackId()
The stack ID.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 Boolean
Whether the stack uses custom cookbooks.final Boolean
Whether the stack automatically associates the OpsWorks Stacks built-in security groups with the stack's layers.final String
vpcId()
The VPC ID; applicable only if the stack is running in a VPC.Methods inherited from interface software.amazon.awssdk.utils.builder.ToCopyableBuilder
copy
-
Method Details
-
stackId
-
name
The stack name. Stack names can be a maximum of 64 characters.
- Returns:
- The stack name. Stack names can be a maximum of 64 characters.
-
arn
-
region
The stack Amazon Web Services Region, such as
ap-northeast-2
. For more information about Amazon Web Services Regions, see Regions and Endpoints.- Returns:
- The stack Amazon Web Services Region, such as
ap-northeast-2
. For more information about Amazon Web Services Regions, see Regions and Endpoints.
-
vpcId
The VPC ID; applicable only if the stack is running in a VPC.
- Returns:
- The VPC ID; applicable only if the stack is running in a VPC.
-
attributes
The stack's attributes.
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
hasAttributes()
method.- Returns:
- The stack's attributes.
-
hasAttributes
public final boolean hasAttributes()For responses, this returns true if the service returned a value for the Attributes 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. -
attributesAsStrings
The stack's attributes.
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
hasAttributes()
method.- Returns:
- The stack's attributes.
-
serviceRoleArn
The stack Identity and Access Management (IAM) role.
- Returns:
- The stack Identity and Access Management (IAM) role.
-
defaultInstanceProfileArn
The ARN of an IAM profile that is the default profile for all of the stack's EC2 instances. For more information about IAM ARNs, see Using Identifiers.
- Returns:
- The ARN of an IAM profile that is the default profile for all of the stack's EC2 instances. For more information about IAM ARNs, see Using Identifiers.
-
defaultOs
The stack's default operating system.
- Returns:
- The stack's default operating system.
-
hostnameTheme
The stack host name theme, with spaces replaced by underscores.
- Returns:
- The stack host name theme, with spaces replaced by underscores.
-
defaultAvailabilityZone
The stack's default Availability Zone. For more information, see Regions and Endpoints.
- Returns:
- The stack's default Availability Zone. For more information, see Regions and Endpoints.
-
defaultSubnetId
The default subnet ID; applicable only if the stack is running in a VPC.
- Returns:
- The default subnet ID; applicable only if the stack is running in a VPC.
-
customJson
A JSON object that contains user-defined attributes to be added to the stack configuration and deployment attributes. You can use custom JSON to override the corresponding default stack configuration attribute values or to pass data to recipes. The string should be in the following format:
"{\"key1\": \"value1\", \"key2\": \"value2\",...}"
For more information on custom JSON, see Use Custom JSON to Modify the Stack Configuration Attributes.
- Returns:
- A JSON object that contains user-defined attributes to be added to the stack configuration and deployment
attributes. You can use custom JSON to override the corresponding default stack configuration attribute
values or to pass data to recipes. The string should be in the following format:
"{\"key1\": \"value1\", \"key2\": \"value2\",...}"
For more information on custom JSON, see Use Custom JSON to Modify the Stack Configuration Attributes.
-
configurationManager
The configuration manager.
- Returns:
- The configuration manager.
-
chefConfiguration
A
ChefConfiguration
object that specifies whether to enable Berkshelf and the Berkshelf version. For more information, see Create a New Stack.- Returns:
- A
ChefConfiguration
object that specifies whether to enable Berkshelf and the Berkshelf version. For more information, see Create a New Stack.
-
useCustomCookbooks
Whether the stack uses custom cookbooks.
- Returns:
- Whether the stack uses custom cookbooks.
-
useOpsworksSecurityGroups
Whether the stack automatically associates the OpsWorks Stacks built-in security groups with the stack's layers.
- Returns:
- Whether the stack automatically associates the OpsWorks Stacks built-in security groups with the stack's layers.
-
customCookbooksSource
Contains the information required to retrieve an app or cookbook from a repository. For more information, see Adding Apps or Cookbooks and Recipes.
- Returns:
- Contains the information required to retrieve an app or cookbook from a repository. For more information, see Adding Apps or Cookbooks and Recipes.
-
defaultSshKeyName
A default Amazon EC2 key pair for the stack's instances. You can override this value when you create or update an instance.
- Returns:
- A default Amazon EC2 key pair for the stack's instances. You can override this value when you create or update an instance.
-
createdAt
The date when the stack was created.
- Returns:
- The date when the stack was created.
-
defaultRootDeviceType
The default root device type. This value is used by default for all instances in the stack, but you can override it when you create an instance. For more information, see Storage for the Root Device.
If the service returns an enum value that is not available in the current SDK version,
defaultRootDeviceType
will returnRootDeviceType.UNKNOWN_TO_SDK_VERSION
. The raw value returned by the service is available fromdefaultRootDeviceTypeAsString()
.- Returns:
- The default root device type. This value is used by default for all instances in the stack, but you can override it when you create an instance. For more information, see Storage for the Root Device.
- See Also:
-
defaultRootDeviceTypeAsString
The default root device type. This value is used by default for all instances in the stack, but you can override it when you create an instance. For more information, see Storage for the Root Device.
If the service returns an enum value that is not available in the current SDK version,
defaultRootDeviceType
will returnRootDeviceType.UNKNOWN_TO_SDK_VERSION
. The raw value returned by the service is available fromdefaultRootDeviceTypeAsString()
.- Returns:
- The default root device type. This value is used by default for all instances in the stack, but you can override it when you create an instance. For more information, see Storage for the Root Device.
- See Also:
-
agentVersion
The agent version. This parameter is set to
LATEST
for auto-update. or a version number for a fixed agent version.- Returns:
- The agent version. This parameter is set to
LATEST
for auto-update. or a version number for a fixed agent version.
-
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<Stack.Builder,
Stack> - Returns:
- a builder for type T
-
builder
-
serializableBuilderClass
-
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
-
getValueForField
-
sdkFields
-
sdkFieldNameToField
- Specified by:
sdkFieldNameToField
in interfaceSdkPojo
- Returns:
- The mapping between the field name and its corresponding field.
-