/* * Copyright 2018-2023 Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with * the License. A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions * and limitations under the License. */ package com.amazonaws.services.ec2.model; import java.io.Serializable; import javax.annotation.Generated; import com.amazonaws.AmazonWebServiceRequest; import com.amazonaws.Request; import com.amazonaws.services.ec2.model.transform.CreateVolumeRequestMarshaller; /** * */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class CreateVolumeRequest extends AmazonWebServiceRequest implements Serializable, Cloneable, DryRunSupportedRequest { /** *

* The ID of the Availability Zone in which to create the volume. For example, us-east-1a. *

*/ private String availabilityZone; /** *

* Indicates whether the volume should be encrypted. The effect of setting the encryption state to true * depends on the volume origin (new or from a snapshot), starting encryption state, ownership, and whether * encryption by default is enabled. For more information, see Encryption by * default in the Amazon Elastic Compute Cloud User Guide. *

*

* Encrypted Amazon EBS volumes must be attached to instances that support Amazon EBS encryption. For more * information, see Supported instance types. *

*/ private Boolean encrypted; /** *

* The number of I/O operations per second (IOPS). For gp3, io1, and io2 * volumes, this represents the number of IOPS that are provisioned for the volume. For gp2 volumes, * this represents the baseline performance of the volume and the rate at which the volume accumulates I/O credits * for bursting. *

*

* The following are the supported values for each volume type: *

* *

* io1 and io2 volumes support up to 64,000 IOPS only on Instances * built on the Nitro System. Other instance families support performance up to 32,000 IOPS. *

*

* This parameter is required for io1 and io2 volumes. The default for gp3 * volumes is 3,000 IOPS. This parameter is not supported for gp2, st1, sc1, * or standard volumes. *

*/ private Integer iops; /** *

* The identifier of the Key Management Service (KMS) KMS key to use for Amazon EBS encryption. If this parameter is * not specified, your KMS key for Amazon EBS is used. If KmsKeyId is specified, the encrypted state * must be true. *

*

* You can specify the KMS key using any of the following: *

* *

* Amazon Web Services authenticates the KMS key asynchronously. Therefore, if you specify an ID, alias, or ARN that * is not valid, the action can appear to complete, but eventually fails. *

*/ private String kmsKeyId; /** *

* The Amazon Resource Name (ARN) of the Outpost. *

*/ private String outpostArn; /** *

* The size of the volume, in GiBs. You must specify either a snapshot ID or a volume size. If you specify a * snapshot, the default is the snapshot size. You can specify a volume size that is equal to or larger than the * snapshot size. *

*

* The following are the supported volumes sizes for each volume type: *

* */ private Integer size; /** *

* The snapshot from which to create the volume. You must specify either a snapshot ID or a volume size. *

*/ private String snapshotId; /** *

* The volume type. This parameter can be one of the following values: *

* * *

* Throughput Optimized HDD (st1) and Cold HDD (sc1) volumes can't be used as boot * volumes. *

*
*

* For more information, see Amazon EBS volume types in the * Amazon Elastic Compute Cloud User Guide. *

*

* Default: gp2 *

*/ private String volumeType; /** *

* The tags to apply to the volume during creation. *

*/ private com.amazonaws.internal.SdkInternalList tagSpecifications; /** *

* Indicates whether to enable Amazon EBS Multi-Attach. If you enable Multi-Attach, you can attach the volume to up * to 16 Instances * built on the Nitro System in the same Availability Zone. This parameter is supported with io1 * and io2 volumes only. For more information, see Amazon EBS Multi-Attach in * the Amazon Elastic Compute Cloud User Guide. *

*/ private Boolean multiAttachEnabled; /** *

* The throughput to provision for a volume, with a maximum of 1,000 MiB/s. *

*

* This parameter is valid only for gp3 volumes. *

*

* Valid Range: Minimum value of 125. Maximum value of 1000. *

*/ private Integer throughput; /** *

* Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. For more * information, see Ensure * Idempotency. *

*/ private String clientToken; /** * Default constructor for CreateVolumeRequest object. Callers should use the setter or fluent setter (with...) * methods to initialize the object after creating it. */ public CreateVolumeRequest() { } /** * Constructs a new CreateVolumeRequest object. Callers should use the setter or fluent setter (with...) methods to * initialize any additional object members. * * @param size * The size of the volume, in GiBs. You must specify either a snapshot ID or a volume size. If you specify a * snapshot, the default is the snapshot size. You can specify a volume size that is equal to or larger than * the snapshot size.

*

* The following are the supported volumes sizes for each volume type: *

*