libZSservicesZSamazonka-ebsZSamazonka-ebs
Copyright(c) 2013-2021 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay+amazonka@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone

Amazonka.EBS.StartSnapshot

Description

Creates a new Amazon EBS snapshot. The new snapshot enters the pending state after the request completes.

After creating the snapshot, use PutSnapshotBlock to write blocks of data to the snapshot.

Synopsis

Creating a Request

data StartSnapshot Source #

See: newStartSnapshot smart constructor.

Constructors

StartSnapshot' 

Fields

  • kmsKeyArn :: Maybe (Sensitive Text)

    The Amazon Resource Name (ARN) of the Key Management Service (KMS) key to be used to encrypt the snapshot. If you do not specify a KMS key, the default Amazon Web Services managed KMS key is used.

    If you specify a ParentSnapshotId, omit this parameter; the snapshot will be encrypted using the same KMS key that was used to encrypt the parent snapshot.

    If Encrypted is set to true, you must specify a KMS key ARN.

  • clientToken :: Maybe Text

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. Idempotency ensures that an API request completes only once. With an idempotent request, if the original request completes successfully. The subsequent retries with the same client token return the result from the original successful request and they have no additional effect.

    If you do not specify a client token, one is automatically generated by the Amazon Web Services SDK.

    For more information, see Idempotency for StartSnapshot API in the Amazon Elastic Compute Cloud User Guide.

  • encrypted :: Maybe Bool

    Indicates whether to encrypt the snapshot. To create an encrypted snapshot, specify true. To create an unencrypted snapshot, omit this parameter.

    If you specify a value for ParentSnapshotId, omit this parameter.

    If you specify true, the snapshot is encrypted using the KMS key specified using the KmsKeyArn parameter. If no value is specified for KmsKeyArn, the default KMS key for your account is used. If no default KMS key has been specified for your account, the Amazon Web Services managed KMS key is used. To set a default KMS key for your account, use ModifyEbsDefaultKmsKeyId.

    If your account is enabled for encryption by default, you cannot set this parameter to false. In this case, you can omit this parameter.

    For more information, see Using encryption in the Amazon Elastic Compute Cloud User Guide.

  • parentSnapshotId :: Maybe Text

    The ID of the parent snapshot. If there is no parent snapshot, or if you are creating the first snapshot for an on-premises volume, omit this parameter.

    If your account is enabled for encryption by default, you cannot use an unencrypted snapshot as a parent snapshot. You must first create an encrypted copy of the parent snapshot using CopySnapshot.

  • timeout :: Maybe Natural

    The amount of time (in minutes) after which the snapshot is automatically cancelled if:

    • No blocks are written to the snapshot.
    • The snapshot is not completed after writing the last block of data.

    If no value is specified, the timeout defaults to 60 minutes.

  • description :: Maybe Text

    A description for the snapshot.

  • tags :: Maybe [Tag]

    The tags to apply to the snapshot.

  • volumeSize :: Natural

    The size of the volume, in GiB. The maximum size is 65536 GiB (64 TiB).

Instances

Instances details
Eq StartSnapshot Source # 
Instance details

Defined in Amazonka.EBS.StartSnapshot

Show StartSnapshot Source # 
Instance details

Defined in Amazonka.EBS.StartSnapshot

Generic StartSnapshot Source # 
Instance details

Defined in Amazonka.EBS.StartSnapshot

Associated Types

type Rep StartSnapshot :: Type -> Type #

NFData StartSnapshot Source # 
Instance details

Defined in Amazonka.EBS.StartSnapshot

Methods

rnf :: StartSnapshot -> () #

Hashable StartSnapshot Source # 
Instance details

Defined in Amazonka.EBS.StartSnapshot

ToJSON StartSnapshot Source # 
Instance details

Defined in Amazonka.EBS.StartSnapshot

AWSRequest StartSnapshot Source # 
Instance details

Defined in Amazonka.EBS.StartSnapshot

Associated Types

type AWSResponse StartSnapshot #

ToHeaders StartSnapshot Source # 
Instance details

Defined in Amazonka.EBS.StartSnapshot

ToPath StartSnapshot Source # 
Instance details

Defined in Amazonka.EBS.StartSnapshot

ToQuery StartSnapshot Source # 
Instance details

Defined in Amazonka.EBS.StartSnapshot

type Rep StartSnapshot Source # 
Instance details

Defined in Amazonka.EBS.StartSnapshot

type AWSResponse StartSnapshot Source # 
Instance details

Defined in Amazonka.EBS.StartSnapshot

newStartSnapshot Source #

Create a value of StartSnapshot with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:kmsKeyArn:StartSnapshot', startSnapshot_kmsKeyArn - The Amazon Resource Name (ARN) of the Key Management Service (KMS) key to be used to encrypt the snapshot. If you do not specify a KMS key, the default Amazon Web Services managed KMS key is used.

If you specify a ParentSnapshotId, omit this parameter; the snapshot will be encrypted using the same KMS key that was used to encrypt the parent snapshot.

If Encrypted is set to true, you must specify a KMS key ARN.

$sel:clientToken:StartSnapshot', startSnapshot_clientToken - A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. Idempotency ensures that an API request completes only once. With an idempotent request, if the original request completes successfully. The subsequent retries with the same client token return the result from the original successful request and they have no additional effect.

If you do not specify a client token, one is automatically generated by the Amazon Web Services SDK.

For more information, see Idempotency for StartSnapshot API in the Amazon Elastic Compute Cloud User Guide.

$sel:encrypted:StartSnapshot', startSnapshot_encrypted - Indicates whether to encrypt the snapshot. To create an encrypted snapshot, specify true. To create an unencrypted snapshot, omit this parameter.

If you specify a value for ParentSnapshotId, omit this parameter.

If you specify true, the snapshot is encrypted using the KMS key specified using the KmsKeyArn parameter. If no value is specified for KmsKeyArn, the default KMS key for your account is used. If no default KMS key has been specified for your account, the Amazon Web Services managed KMS key is used. To set a default KMS key for your account, use ModifyEbsDefaultKmsKeyId.

If your account is enabled for encryption by default, you cannot set this parameter to false. In this case, you can omit this parameter.

For more information, see Using encryption in the Amazon Elastic Compute Cloud User Guide.

$sel:parentSnapshotId:StartSnapshot', startSnapshot_parentSnapshotId - The ID of the parent snapshot. If there is no parent snapshot, or if you are creating the first snapshot for an on-premises volume, omit this parameter.

If your account is enabled for encryption by default, you cannot use an unencrypted snapshot as a parent snapshot. You must first create an encrypted copy of the parent snapshot using CopySnapshot.

$sel:timeout:StartSnapshot', startSnapshot_timeout - The amount of time (in minutes) after which the snapshot is automatically cancelled if:

  • No blocks are written to the snapshot.
  • The snapshot is not completed after writing the last block of data.

If no value is specified, the timeout defaults to 60 minutes.

$sel:description:StartSnapshot', startSnapshot_description - A description for the snapshot.

$sel:tags:StartSnapshot', startSnapshot_tags - The tags to apply to the snapshot.

$sel:volumeSize:StartSnapshot', startSnapshot_volumeSize - The size of the volume, in GiB. The maximum size is 65536 GiB (64 TiB).

Request Lenses

startSnapshot_kmsKeyArn :: Lens' StartSnapshot (Maybe Text) Source #

The Amazon Resource Name (ARN) of the Key Management Service (KMS) key to be used to encrypt the snapshot. If you do not specify a KMS key, the default Amazon Web Services managed KMS key is used.

If you specify a ParentSnapshotId, omit this parameter; the snapshot will be encrypted using the same KMS key that was used to encrypt the parent snapshot.

If Encrypted is set to true, you must specify a KMS key ARN.

startSnapshot_clientToken :: Lens' StartSnapshot (Maybe Text) Source #

A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. Idempotency ensures that an API request completes only once. With an idempotent request, if the original request completes successfully. The subsequent retries with the same client token return the result from the original successful request and they have no additional effect.

If you do not specify a client token, one is automatically generated by the Amazon Web Services SDK.

For more information, see Idempotency for StartSnapshot API in the Amazon Elastic Compute Cloud User Guide.

startSnapshot_encrypted :: Lens' StartSnapshot (Maybe Bool) Source #

Indicates whether to encrypt the snapshot. To create an encrypted snapshot, specify true. To create an unencrypted snapshot, omit this parameter.

If you specify a value for ParentSnapshotId, omit this parameter.

If you specify true, the snapshot is encrypted using the KMS key specified using the KmsKeyArn parameter. If no value is specified for KmsKeyArn, the default KMS key for your account is used. If no default KMS key has been specified for your account, the Amazon Web Services managed KMS key is used. To set a default KMS key for your account, use ModifyEbsDefaultKmsKeyId.

If your account is enabled for encryption by default, you cannot set this parameter to false. In this case, you can omit this parameter.

For more information, see Using encryption in the Amazon Elastic Compute Cloud User Guide.

startSnapshot_parentSnapshotId :: Lens' StartSnapshot (Maybe Text) Source #

The ID of the parent snapshot. If there is no parent snapshot, or if you are creating the first snapshot for an on-premises volume, omit this parameter.

If your account is enabled for encryption by default, you cannot use an unencrypted snapshot as a parent snapshot. You must first create an encrypted copy of the parent snapshot using CopySnapshot.

startSnapshot_timeout :: Lens' StartSnapshot (Maybe Natural) Source #

The amount of time (in minutes) after which the snapshot is automatically cancelled if:

  • No blocks are written to the snapshot.
  • The snapshot is not completed after writing the last block of data.

If no value is specified, the timeout defaults to 60 minutes.

startSnapshot_description :: Lens' StartSnapshot (Maybe Text) Source #

A description for the snapshot.

startSnapshot_tags :: Lens' StartSnapshot (Maybe [Tag]) Source #

The tags to apply to the snapshot.

startSnapshot_volumeSize :: Lens' StartSnapshot Natural Source #

The size of the volume, in GiB. The maximum size is 65536 GiB (64 TiB).

Destructuring the Response

data StartSnapshotResponse Source #

See: newStartSnapshotResponse smart constructor.

Constructors

StartSnapshotResponse' 

Fields

Instances

Instances details
Eq StartSnapshotResponse Source # 
Instance details

Defined in Amazonka.EBS.StartSnapshot

Show StartSnapshotResponse Source # 
Instance details

Defined in Amazonka.EBS.StartSnapshot

Generic StartSnapshotResponse Source # 
Instance details

Defined in Amazonka.EBS.StartSnapshot

Associated Types

type Rep StartSnapshotResponse :: Type -> Type #

NFData StartSnapshotResponse Source # 
Instance details

Defined in Amazonka.EBS.StartSnapshot

Methods

rnf :: StartSnapshotResponse -> () #

type Rep StartSnapshotResponse Source # 
Instance details

Defined in Amazonka.EBS.StartSnapshot

newStartSnapshotResponse Source #

Create a value of StartSnapshotResponse with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:blockSize:StartSnapshotResponse', startSnapshotResponse_blockSize - The size of the blocks in the snapshot, in bytes.

$sel:status:StartSnapshotResponse', startSnapshotResponse_status - The status of the snapshot.

$sel:kmsKeyArn:StartSnapshot', startSnapshotResponse_kmsKeyArn - The Amazon Resource Name (ARN) of the Key Management Service (KMS) key used to encrypt the snapshot.

$sel:startTime:StartSnapshotResponse', startSnapshotResponse_startTime - The timestamp when the snapshot was created.

$sel:volumeSize:StartSnapshot', startSnapshotResponse_volumeSize - The size of the volume, in GiB.

$sel:ownerId:StartSnapshotResponse', startSnapshotResponse_ownerId - The Amazon Web Services account ID of the snapshot owner.

$sel:parentSnapshotId:StartSnapshot', startSnapshotResponse_parentSnapshotId - The ID of the parent snapshot.

$sel:description:StartSnapshot', startSnapshotResponse_description - The description of the snapshot.

$sel:tags:StartSnapshot', startSnapshotResponse_tags - The tags applied to the snapshot. You can specify up to 50 tags per snapshot. For more information, see Tagging your Amazon EC2 resources in the Amazon Elastic Compute Cloud User Guide.

$sel:snapshotId:StartSnapshotResponse', startSnapshotResponse_snapshotId - The ID of the snapshot.

$sel:httpStatus:StartSnapshotResponse', startSnapshotResponse_httpStatus - The response's http status code.

Response Lenses

startSnapshotResponse_blockSize :: Lens' StartSnapshotResponse (Maybe Int) Source #

The size of the blocks in the snapshot, in bytes.

startSnapshotResponse_kmsKeyArn :: Lens' StartSnapshotResponse (Maybe Text) Source #

The Amazon Resource Name (ARN) of the Key Management Service (KMS) key used to encrypt the snapshot.

startSnapshotResponse_startTime :: Lens' StartSnapshotResponse (Maybe UTCTime) Source #

The timestamp when the snapshot was created.

startSnapshotResponse_ownerId :: Lens' StartSnapshotResponse (Maybe Text) Source #

The Amazon Web Services account ID of the snapshot owner.

startSnapshotResponse_tags :: Lens' StartSnapshotResponse (Maybe [Tag]) Source #

The tags applied to the snapshot. You can specify up to 50 tags per snapshot. For more information, see Tagging your Amazon EC2 resources in the Amazon Elastic Compute Cloud User Guide.