From d0dfde1c03e7dc1f7340d52666a88d542bb381ce Mon Sep 17 00:00:00 2001 From: awssdkgo Date: Mon, 12 Apr 2021 18:14:27 +0000 Subject: [PATCH] Release v1.38.18 (2021-04-12) === ### Service Client Updates * `service/codebuild`: Updates service API and documentation * AWS CodeBuild now allows you to set the access permissions for build artifacts, project artifacts, and log files that are uploaded to an Amazon S3 bucket that is owned by another account. * `service/fsx`: Updates service API, documentation, and examples --- CHANGELOG.md | 8 + aws/endpoints/defaults.go | 38 + aws/version.go | 2 +- models/apis/codebuild/2016-10-06/api-2.json | 17 +- models/apis/codebuild/2016-10-06/docs-2.json | 18 +- models/apis/fsx/2018-03-01/api-2.json | 121 ++- models/apis/fsx/2018-03-01/docs-2.json | 99 ++- models/apis/fsx/2018-03-01/examples-1.json | 43 ++ models/endpoints/endpoints.json | 36 + service/codebuild/api.go | 192 ++++- service/fsx/api.go | 773 ++++++++++++++++++- service/fsx/errors.go | 46 ++ service/fsx/examples_test.go | 52 ++ service/fsx/fsxiface/interface.go | 4 + 14 files changed, 1381 insertions(+), 68 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 285baed510..c34e80223f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,11 @@ +Release v1.38.18 (2021-04-12) +=== + +### Service Client Updates +* `service/codebuild`: Updates service API and documentation + * AWS CodeBuild now allows you to set the access permissions for build artifacts, project artifacts, and log files that are uploaded to an Amazon S3 bucket that is owned by another account. +* `service/fsx`: Updates service API, documentation, and examples + Release v1.38.17 (2021-04-09) === diff --git a/aws/endpoints/defaults.go b/aws/endpoints/defaults.go index 978c077e77..c102146b3f 100644 --- a/aws/endpoints/defaults.go +++ b/aws/endpoints/defaults.go @@ -1791,6 +1791,7 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-west-2": endpoint{}, "us-east-1": endpoint{}, @@ -3399,6 +3400,7 @@ var awsPartition = partition{ "ap-east-1": endpoint{}, "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, + "ap-northeast-3": endpoint{}, "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, @@ -4093,6 +4095,14 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, + "lookoutequipment": service{ + + Endpoints: endpoints{ + "ap-northeast-2": endpoint{}, + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + }, + }, "lookoutvision": service{ Endpoints: endpoints{ @@ -7871,6 +7881,13 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, + "mq": service{ + + Endpoints: endpoints{ + "cn-north-1": endpoint{}, + "cn-northwest-1": endpoint{}, + }, + }, "neptune": service{ Endpoints: endpoints{ @@ -8963,6 +8980,27 @@ var awsusgovPartition = partition{ "us-gov-west-1": endpoint{}, }, }, + "fms": service{ + Defaults: endpoint{ + Protocols: []string{"https"}, + }, + Endpoints: endpoints{ + "fips-us-gov-east-1": endpoint{ + Hostname: "fms-fips.us-gov-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-gov-east-1", + }, + }, + "fips-us-gov-west-1": endpoint{ + Hostname: "fms-fips.us-gov-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-gov-west-1", + }, + }, + "us-gov-east-1": endpoint{}, + "us-gov-west-1": endpoint{}, + }, + }, "fsx": service{ Endpoints: endpoints{ diff --git a/aws/version.go b/aws/version.go index 5f7e4b3833..059a9bd297 100644 --- a/aws/version.go +++ b/aws/version.go @@ -5,4 +5,4 @@ package aws const SDKName = "aws-sdk-go" // SDKVersion is the version of this SDK -const SDKVersion = "1.38.17" +const SDKVersion = "1.38.18" diff --git a/models/apis/codebuild/2016-10-06/api-2.json b/models/apis/codebuild/2016-10-06/api-2.json index 2d6916d457..343ea5861e 100644 --- a/models/apis/codebuild/2016-10-06/api-2.json +++ b/models/apis/codebuild/2016-10-06/api-2.json @@ -699,6 +699,14 @@ } }, "Boolean":{"type":"boolean"}, + "BucketOwnerAccess":{ + "type":"string", + "enum":[ + "NONE", + "READ_ONLY", + "FULL" + ] + }, "Build":{ "type":"structure", "members":{ @@ -744,7 +752,8 @@ "md5sum":{"shape":"String"}, "overrideArtifactName":{"shape":"WrapperBoolean"}, "encryptionDisabled":{"shape":"WrapperBoolean"}, - "artifactIdentifier":{"shape":"String"} + "artifactIdentifier":{"shape":"String"}, + "bucketOwnerAccess":{"shape":"BucketOwnerAccess"} } }, "BuildArtifactsList":{ @@ -1721,7 +1730,8 @@ "packaging":{"shape":"ArtifactPackaging"}, "overrideArtifactName":{"shape":"WrapperBoolean"}, "encryptionDisabled":{"shape":"WrapperBoolean"}, - "artifactIdentifier":{"shape":"String"} + "artifactIdentifier":{"shape":"String"}, + "bucketOwnerAccess":{"shape":"BucketOwnerAccess"} } }, "ProjectArtifactsList":{ @@ -2114,7 +2124,8 @@ "members":{ "status":{"shape":"LogsConfigStatusType"}, "location":{"shape":"String"}, - "encryptionDisabled":{"shape":"WrapperBoolean"} + "encryptionDisabled":{"shape":"WrapperBoolean"}, + "bucketOwnerAccess":{"shape":"BucketOwnerAccess"} } }, "S3ReportExportConfig":{ diff --git a/models/apis/codebuild/2016-10-06/docs-2.json b/models/apis/codebuild/2016-10-06/docs-2.json index 0a62d8384a..7d467d4dce 100644 --- a/models/apis/codebuild/2016-10-06/docs-2.json +++ b/models/apis/codebuild/2016-10-06/docs-2.json @@ -156,6 +156,14 @@ "UpdateWebhookInput$rotateSecret": "

A boolean value that specifies whether the associated GitHub repository's secret token should be updated. If you use Bitbucket for your repository, rotateSecret is ignored.

" } }, + "BucketOwnerAccess": { + "base": "

Specifies the access for objects that are uploaded to an Amazon S3 bucket that is owned by another account.

By default, only the account that uploads the objects to the bucket has access to these objects. This property allows you to give the bucket owner access to these objects.

NONE

The bucket owner does not have access to the objects. This is the default.

READ_ONLY

The bucket owner has read only access to the objects. The uploading account retains ownership of the objects.

FULL

The bucket owner has full access to the objects. Object ownership is determined by the following criteria:

  • If the bucket is configured with the Bucket owner preferred setting, the bucket owner owns the objects. The uploading account will have object access as specified by the bucket's policy.

  • Otherwise, the uploading account retains ownership of the objects.

For more information about Amazon S3 object ownership, see Controlling ownership of uploaded objects using S3 Object Ownership in the Amazon Simple Storage Service User Guide.

", + "refs": { + "BuildArtifacts$bucketOwnerAccess": null, + "ProjectArtifacts$bucketOwnerAccess": null, + "S3LogsConfig$bucketOwnerAccess": null + } + }, "Build": { "base": "

Information about a build.

", "refs": { @@ -564,7 +572,7 @@ } }, "ExportedEnvironmentVariable": { - "base": "

Information about an exported environment variable.

", + "base": "

Contains information about an exported environment variable.

Exported environment variables are used in conjunction with AWS CodePipeline to export environment variables from the current build stage to subsequent stages in the pipeline. For more information, see Working with variables in the AWS CodePipeline User Guide.

During a build, the value of a variable is available starting with the install phase. It can be updated between the start of the install phase and the end of the post_build phase. After the post_build phase ends, the value of exported variables cannot change.

", "refs": { "ExportedEnvironmentVariables$member": null } @@ -572,7 +580,7 @@ "ExportedEnvironmentVariables": { "base": null, "refs": { - "Build$exportedEnvironmentVariables": "

A list of exported environment variables for this build.

" + "Build$exportedEnvironmentVariables": "

A list of exported environment variables for this build.

Exported environment variables are used in conjunction with AWS CodePipeline to export environment variables from the current build stage to subsequent stages in the pipeline. For more information, see Working with variables in the AWS CodePipeline User Guide.

" } }, "FileSystemType": { @@ -874,7 +882,7 @@ "DeleteSourceCredentialsOutput$arn": "

The Amazon Resource Name (ARN) of the token.

", "DescribeCodeCoveragesInput$reportArn": "

The ARN of the report for which test cases are returned.

", "EnvironmentVariable$name": "

The name or key of the environment variable.

", - "ExportedEnvironmentVariable$name": "

The name of this exported environment variable.

", + "ExportedEnvironmentVariable$name": "

The name of the exported environment variable.

", "GetReportGroupTrendInput$reportGroupArn": "

The ARN of the report group that contains the reports to analyze.

", "GetResourcePolicyInput$resourceArn": "

The ARN of the resource that is associated with the resource policy.

", "GetResourcePolicyOutput$policy": "

The resource policy for the resource identified by the input ARN parameter.

", @@ -1549,7 +1557,7 @@ "EnvironmentImage$name": "

The name of the Docker image.

", "EnvironmentImage$description": "

The description of the Docker image.

", "EnvironmentVariable$value": "

The value of the environment variable.

We strongly discourage the use of PLAINTEXT environment variables to store sensitive values, especially AWS secret key IDs and secret access keys. PLAINTEXT environment variables can be displayed in plain text using the AWS CodeBuild console and the AWS Command Line Interface (AWS CLI). For sensitive values, we recommend you use an environment variable of type PARAMETER_STORE or SECRETS_MANAGER.

", - "ExportedEnvironmentVariable$value": "

The value assigned to this exported environment variable.

During a build, the value of a variable is available starting with the install phase. It can be updated between the start of the install phase and the end of the post_build phase. After the post_build phase ends, the value of exported variables cannot change.

", + "ExportedEnvironmentVariable$value": "

The value assigned to the exported environment variable.

", "ImageVersions$member": null, "ListBuildBatchesForProjectInput$nextToken": "

The nextToken value returned from a previous call to ListBuildBatchesForProject. This specifies the next item to return. To return the beginning of the list, exclude this parameter.

", "ListBuildBatchesForProjectOutput$nextToken": "

If there are more items to return, this contains a token that is passed to a subsequent call to ListBuildBatchesForProject to retrieve the next set of items.

", @@ -1798,7 +1806,7 @@ "refs": { "BuildArtifacts$overrideArtifactName": "

If this flag is set, a name specified in the buildspec file overrides the artifact name. The name specified in a buildspec file is calculated at build time and uses the Shell Command Language. For example, you can append a date and time to your artifact name so that it is always unique.

", "BuildArtifacts$encryptionDisabled": "

Information that tells you if encryption for build artifacts is disabled.

", - "BuildBatch$debugSessionEnabled": "

Specifies if session debugging is enabled for this batch build. For more information, see Viewing a running build in Session Manager. Batch session debugging is not supported for matrix batch builds.

", + "BuildBatch$debugSessionEnabled": "

Specifies if session debugging is enabled for this batch build. For more information, see Viewing a running build in Session Manager. Batch session debugging is not supported for matrix batch builds.

", "CreateProjectInput$badgeEnabled": "

Set this to true to generate a publicly accessible URL for your project's build badge.

", "DebugSession$sessionEnabled": "

Specifies if session debugging is enabled for this build.

", "GitSubmodulesConfig$fetchSubmodules": "

Set to true to fetch Git submodules for your AWS CodeBuild build project.

", diff --git a/models/apis/fsx/2018-03-01/api-2.json b/models/apis/fsx/2018-03-01/api-2.json index 4807c2c082..266c35c6f8 100644 --- a/models/apis/fsx/2018-03-01/api-2.json +++ b/models/apis/fsx/2018-03-01/api-2.json @@ -44,6 +44,29 @@ ], "idempotent":true }, + "CopyBackup":{ + "name":"CopyBackup", + "http":{ + "method":"POST", + "requestUri":"/" + }, + "input":{"shape":"CopyBackupRequest"}, + "output":{"shape":"CopyBackupResponse"}, + "errors":[ + {"shape":"BadRequest"}, + {"shape":"BackupNotFound"}, + {"shape":"ServiceLimitExceeded"}, + {"shape":"UnsupportedOperation"}, + {"shape":"IncompatibleParameterError"}, + {"shape":"InternalServerError"}, + {"shape":"InvalidSourceKmsKey"}, + {"shape":"InvalidDestinationKmsKey"}, + {"shape":"InvalidRegion"}, + {"shape":"SourceBackupUnavailable"}, + {"shape":"IncompatibleRegionForMultiAZ"} + ], + "idempotent":true + }, "CreateBackup":{ "name":"CreateBackup", "http":{ @@ -137,7 +160,8 @@ {"shape":"BackupNotFound"}, {"shape":"BackupRestoring"}, {"shape":"IncompatibleParameterError"}, - {"shape":"InternalServerError"} + {"shape":"InternalServerError"}, + {"shape":"BackupBeingCopied"} ], "idempotent":true }, @@ -310,7 +334,8 @@ "type":"structure", "members":{ "DomainName":{"shape":"ActiveDirectoryFullyQualifiedName"}, - "ActiveDirectoryId":{"shape":"DirectoryId"} + "ActiveDirectoryId":{"shape":"DirectoryId"}, + "ResourceARN":{"shape":"ResourceARN"} } }, "ActiveDirectoryError":{ @@ -462,9 +487,20 @@ "ResourceARN":{"shape":"ResourceARN"}, "Tags":{"shape":"Tags"}, "FileSystem":{"shape":"FileSystem"}, - "DirectoryInformation":{"shape":"ActiveDirectoryBackupAttributes"} + "DirectoryInformation":{"shape":"ActiveDirectoryBackupAttributes"}, + "OwnerId":{"shape":"AWSAccountId"}, + "SourceBackupId":{"shape":"BackupId"}, + "SourceBackupRegion":{"shape":"Region"} } }, + "BackupBeingCopied":{ + "type":"structure", + "members":{ + "Message":{"shape":"ErrorMessage"}, + "BackupId":{"shape":"BackupId"} + }, + "exception":true + }, "BackupFailureDetails":{ "type":"structure", "members":{ @@ -497,7 +533,8 @@ "TRANSFERRING", "DELETED", "FAILED", - "PENDING" + "PENDING", + "COPYING" ] }, "BackupNotFound":{ @@ -565,6 +602,27 @@ "Scope":{"shape":"ReportScope"} } }, + "CopyBackupRequest":{ + "type":"structure", + "required":["SourceBackupId"], + "members":{ + "ClientRequestToken":{ + "shape":"ClientRequestToken", + "idempotencyToken":true + }, + "SourceBackupId":{"shape":"SourceBackupId"}, + "SourceRegion":{"shape":"Region"}, + "KmsKeyId":{"shape":"KmsKeyId"}, + "CopyTags":{"shape":"Flag"}, + "Tags":{"shape":"Tags"} + } + }, + "CopyBackupResponse":{ + "type":"structure", + "members":{ + "Backup":{"shape":"Backup"} + } + }, "CreateBackupRequest":{ "type":"structure", "required":["FileSystemId"], @@ -625,7 +683,8 @@ "Tags":{"shape":"Tags"}, "WindowsConfiguration":{"shape":"CreateFileSystemWindowsConfiguration"}, "LustreConfiguration":{"shape":"CreateFileSystemLustreConfiguration"}, - "StorageType":{"shape":"StorageType"} + "StorageType":{"shape":"StorageType"}, + "KmsKeyId":{"shape":"KmsKeyId"} } }, "CreateFileSystemFromBackupResponse":{ @@ -1181,6 +1240,13 @@ }, "exception":true }, + "IncompatibleRegionForMultiAZ":{ + "type":"structure", + "members":{ + "Message":{"shape":"ErrorMessage"} + }, + "exception":true + }, "InternalServerError":{ "type":"structure", "members":{ @@ -1189,6 +1255,13 @@ "exception":true, "fault":true }, + "InvalidDestinationKmsKey":{ + "type":"structure", + "members":{ + "Message":{"shape":"ErrorMessage"} + }, + "exception":true + }, "InvalidExportPath":{ "type":"structure", "members":{ @@ -1219,6 +1292,20 @@ }, "exception":true }, + "InvalidRegion":{ + "type":"structure", + "members":{ + "Message":{"shape":"ErrorMessage"} + }, + "exception":true + }, + "InvalidSourceKmsKey":{ + "type":"structure", + "members":{ + "Message":{"shape":"ErrorMessage"} + }, + "exception":true + }, "IpAddress":{ "type":"string", "max":15, @@ -1344,6 +1431,12 @@ "max":100, "min":0 }, + "Region":{ + "type":"string", + "max":20, + "min":1, + "pattern":"^[a-z0-9-]{1,20}$" + }, "ReportFormat":{ "type":"string", "enum":["REPORT_CSV_20191124"] @@ -1429,7 +1522,9 @@ "FILE_SYSTEM_COUNT", "TOTAL_THROUGHPUT_CAPACITY", "TOTAL_STORAGE", - "TOTAL_USER_INITIATED_BACKUPS" + "TOTAL_USER_INITIATED_BACKUPS", + "TOTAL_USER_TAGS", + "TOTAL_IN_PROGRESS_COPY_BACKUPS" ] }, "ServiceLimitExceeded":{ @@ -1441,6 +1536,20 @@ }, "exception":true }, + "SourceBackupId":{ + "type":"string", + "max":128, + "min":12, + "pattern":"^(backup-[0-9a-f]{8,})$" + }, + "SourceBackupUnavailable":{ + "type":"structure", + "members":{ + "Message":{"shape":"ErrorMessage"}, + "BackupId":{"shape":"BackupId"} + }, + "exception":true + }, "StartTime":{"type":"timestamp"}, "Status":{ "type":"string", diff --git a/models/apis/fsx/2018-03-01/docs-2.json b/models/apis/fsx/2018-03-01/docs-2.json index 73f90b2c77..d223b4d56b 100644 --- a/models/apis/fsx/2018-03-01/docs-2.json +++ b/models/apis/fsx/2018-03-01/docs-2.json @@ -4,6 +4,7 @@ "operations": { "AssociateFileSystemAliases": "

Use this action to associate one or more Domain Name Server (DNS) aliases with an existing Amazon FSx for Windows File Server file system. A file systen can have a maximum of 50 DNS aliases associated with it at any one time. If you try to associate a DNS alias that is already associated with the file system, FSx takes no action on that alias in the request. For more information, see Working with DNS Aliases and Walkthrough 5: Using DNS aliases to access your file system, including additional steps you must take to be able to access your file system using a DNS alias.

The system response shows the DNS aliases that Amazon FSx is attempting to associate with the file system. Use the API operation to monitor the status of the aliases Amazon FSx is associating with the file system.

", "CancelDataRepositoryTask": "

Cancels an existing Amazon FSx for Lustre data repository task if that task is in either the PENDING or EXECUTING state. When you cancel a task, Amazon FSx does the following.

", + "CopyBackup": "

Copies an existing backup within the same AWS account to another Region (cross-Region copy) or within the same Region (in-Region copy). You can have up to five backup copy requests in progress to a single destination Region per account.

You can use cross-Region backup copies for cross-region disaster recovery. You periodically take backups and copy them to another Region so that in the event of a disaster in the primary Region, you can restore from backup and recover availability quickly in the other Region. You can make cross-Region copies only within your AWS partition.

You can also use backup copies to clone your file data set to another Region or within the same Region.

You can use the SourceRegion parameter to specify the AWS Region from which the backup will be copied. For example, if you make the call from the us-west-1 Region and want to copy a backup from the us-east-2 Region, you specify us-east-2 in the SourceRegion parameter to make a cross-Region copy. If you don't specify a Region, the backup copy is created in the same Region where the request is sent from (in-Region copy).

For more information on creating backup copies, see Copying backups in the Amazon FSx for Windows User Guide and Copying backups in the Amazon FSx for Lustre User Guide.

", "CreateBackup": "

Creates a backup of an existing Amazon FSx file system. Creating regular backups for your file system is a best practice, enabling you to restore a file system from a backup if an issue arises with the original file system.

For Amazon FSx for Lustre file systems, you can create a backup only for file systems with the following configuration:

For more information about backing up Amazon FSx for Lustre file systems, see Working with FSx for Lustre backups.

For more information about backing up Amazon FSx for Windows file systems, see Working with FSx for Windows backups.

If a backup with the specified client request token exists, and the parameters match, this operation returns the description of the existing backup. If a backup specified client request token exists, and the parameters don't match, this operation returns IncompatibleParameterError. If a backup with the specified client request token doesn't exist, CreateBackup does the following:

By using the idempotent operation, you can retry a CreateBackup operation without the risk of creating an extra backup. This approach can be useful when an initial call fails in a way that makes it unclear whether a backup was created. If you use the same client request token and the initial call created a backup, the operation returns a successful result because all the parameters are the same.

The CreateBackup operation returns while the backup's lifecycle state is still CREATING. You can check the backup creation status by calling the DescribeBackups operation, which returns the backup state along with other information.

", "CreateDataRepositoryTask": "

Creates an Amazon FSx for Lustre data repository task. You use data repository tasks to perform bulk operations between your Amazon FSx file system and its linked data repository. An example of a data repository task is exporting any data and metadata changes, including POSIX metadata, to files, directories, and symbolic links (symlinks) from your FSx file system to its linked data repository. A CreateDataRepositoryTask operation will fail if a data repository is not linked to the FSx file system. To learn more about data repository tasks, see Data Repository Tasks. To learn more about linking a data repository to your file system, see Linking your file system to an S3 bucket.

", "CreateFileSystem": "

Creates a new, empty Amazon FSx file system.

If a file system with the specified client request token exists and the parameters match, CreateFileSystem returns the description of the existing file system. If a file system specified client request token exists and the parameters don't match, this call returns IncompatibleParameterError. If a file system with the specified client request token doesn't exist, CreateFileSystem does the following:

This operation requires a client request token in the request that Amazon FSx uses to ensure idempotent creation. This means that calling the operation multiple times with the same client request token has no effect. By using the idempotent operation, you can retry a CreateFileSystem operation without the risk of creating an extra file system. This approach can be useful when an initial call fails in a way that makes it unclear whether a file system was created. Examples are if a transport level timeout occurred, or your connection was reset. If you use the same client request token and the initial call created a file system, the client receives success as long as the parameters are the same.

The CreateFileSystem call returns while the file system's lifecycle state is still CREATING. You can check the file-system creation status by calling the DescribeFileSystems operation, which returns the file system state along with other information.

", @@ -24,6 +25,7 @@ "AWSAccountId": { "base": "

An AWS account ID. This ID is a 12-digit number that you use to construct Amazon Resource Names (ARNs) for resources.

", "refs": { + "Backup$OwnerId": null, "FileSystem$OwnerId": "

The AWS account that created the file system. If the file system was created by an AWS Identity and Access Management (IAM) user, the AWS account to which the IAM user belongs is the owner.

" } }, @@ -100,7 +102,7 @@ "AlternateDNSName": { "base": null, "refs": { - "Alias$Name": "

The name of the DNS alias. The alias name has to meet the following requirements:

For DNS names, Amazon FSx stores alphabetic characters as lowercase letters (a-z), regardless of how you specify them: as uppercase letters, lowercase letters, or the corresponding letters in escape codes.

", + "Alias$Name": "

The name of the DNS alias. The alias name has to meet the following requirements:

For DNS names, Amazon FSx stores alphabetic characters as lowercase letters (a-z), regardless of how you specify them: as uppercase letters, lowercase letters, or the corresponding letters in escape codes.

", "AlternateDNSNames$member": null } }, @@ -108,7 +110,7 @@ "base": null, "refs": { "AssociateFileSystemAliasesRequest$Aliases": "

An array of one or more DNS alias names to associate with the file system. The alias name has to comply with the following formatting requirements:

For DNS alias names, Amazon FSx stores alphabetic characters as lowercase letters (a-z), regardless of how you specify them: as uppercase letters, lowercase letters, or the corresponding letters in escape codes.

", - "CreateFileSystemWindowsConfiguration$Aliases": "

An array of one or more DNS alias names that you want to associate with the Amazon FSx file system. Aliases allow you to use existing DNS names to access the data in your Amazon FSx file system. You can associate up to 50 aliases with a file system at any time. You can associate additional DNS aliases after you create the file system using the AssociateFileSystemAliases operation. You can remove DNS aliases from the file system after it is created using the DisassociateFileSystemAliases operation. You only need to specify the alias name in the request payload.

For more information, see Working with DNS Aliases and Walkthrough 5: Using DNS aliases to access your file system, including additional steps you must take to be able to access your file system using a DNS alias.

An alias name has to meet the following requirements:

For DNS alias names, Amazon FSx stores alphabetic characters as lowercase letters (a-z), regardless of how you specify them: as uppercase letters, lowercase letters, or the corresponding letters in escape codes.

", + "CreateFileSystemWindowsConfiguration$Aliases": "

An array of one or more DNS alias names that you want to associate with the Amazon FSx file system. Aliases allow you to use existing DNS names to access the data in your Amazon FSx file system. You can associate up to 50 aliases with a file system at any time. You can associate additional DNS aliases after you create the file system using the AssociateFileSystemAliases operation. You can remove DNS aliases from the file system after it is created using the DisassociateFileSystemAliases operation. You only need to specify the alias name in the request payload.

For more information, see Working with DNS Aliases and Walkthrough 5: Using DNS aliases to access your file system, including additional steps you must take to be able to access your file system using a DNS alias.

An alias name has to meet the following requirements:

For DNS alias names, Amazon FSx stores alphabetic characters as lowercase letters (a-z), regardless of how you specify them: as uppercase letters, lowercase letters, or the corresponding letters in escape codes.

", "DisassociateFileSystemAliasesRequest$Aliases": "

An array of one or more DNS alias names to disassociate, or remove, from the file system.

" } }, @@ -152,12 +154,18 @@ } }, "Backup": { - "base": "

A backup of an Amazon FSx file system. For more information see:

", + "base": "

A backup of an Amazon FSx file system.

", "refs": { "Backups$member": null, + "CopyBackupResponse$Backup": null, "CreateBackupResponse$Backup": "

A description of the backup.

" } }, + "BackupBeingCopied": { + "base": "

You can't delete a backup while it's being copied.

", + "refs": { + } + }, "BackupFailureDetails": { "base": "

If backup creation fails, this structure contains the details of that failure.

", "refs": { @@ -165,15 +173,18 @@ } }, "BackupId": { - "base": "

The ID of the backup. Specifies the backup to use if you're creating a file system from an existing backup.

", + "base": "

The ID of the source backup. Specifies the backup you are copying.

", "refs": { "Backup$BackupId": "

The ID of the backup.

", + "Backup$SourceBackupId": null, + "BackupBeingCopied$BackupId": null, "BackupIds$member": null, "CreateFileSystemFromBackupRequest$BackupId": null, "DeleteBackupRequest$BackupId": "

The ID of the backup you want to delete.

", "DeleteBackupResponse$BackupId": "

The ID of the backup deleted.

", "DeleteFileSystemLustreResponse$FinalBackupId": "

The ID of the final backup for this file system.

", - "DeleteFileSystemWindowsResponse$FinalBackupId": "

The ID of the final backup for this file system.

" + "DeleteFileSystemWindowsResponse$FinalBackupId": "

The ID of the final backup for this file system.

", + "SourceBackupUnavailable$BackupId": null } }, "BackupIds": { @@ -188,9 +199,9 @@ } }, "BackupLifecycle": { - "base": "

The lifecycle status of the backup.

", + "base": "

The lifecycle status of the backup.

", "refs": { - "Backup$Lifecycle": "

The lifecycle status of the backup.

", + "Backup$Lifecycle": "

The lifecycle status of the backup.

", "DeleteBackupResponse$Lifecycle": "

The lifecycle of the backup. Should be DELETED.

" } }, @@ -213,7 +224,7 @@ "Backups": { "base": "

A list of file system backups.

", "refs": { - "DescribeBackupsResponse$Backups": "

Any array of backups.

" + "DescribeBackupsResponse$Backups": "

An array of backups.

" } }, "BadRequest": { @@ -235,6 +246,7 @@ "base": "

(Optional) An idempotency token for resource creation, in a string of up to 64 ASCII characters. This token is automatically filled on your behalf when you use the AWS Command Line Interface (AWS CLI) or an AWS SDK.

", "refs": { "AssociateFileSystemAliasesRequest$ClientRequestToken": null, + "CopyBackupRequest$ClientRequestToken": null, "CreateBackupRequest$ClientRequestToken": "

(Optional) A string of up to 64 ASCII characters that Amazon FSx uses to ensure idempotent creation. This string is automatically filled on your behalf when you use the AWS Command Line Interface (AWS CLI) or an AWS SDK.

", "CreateDataRepositoryTaskRequest$ClientRequestToken": null, "CreateFileSystemFromBackupRequest$ClientRequestToken": "

A string of up to 64 ASCII characters that Amazon FSx uses to ensure idempotent creation. This string is automatically filled on your behalf when you use the AWS Command Line Interface (AWS CLI) or an AWS SDK.

", @@ -253,6 +265,16 @@ "DataRepositoryTask$Report": null } }, + "CopyBackupRequest": { + "base": null, + "refs": { + } + }, + "CopyBackupResponse": { + "base": null, + "refs": { + } + }, "CreateBackupRequest": { "base": "

The request object for the CreateBackup operation.

", "refs": { @@ -538,7 +560,7 @@ "ActiveDirectoryBackupAttributes$ActiveDirectoryId": "

The ID of the AWS Managed Microsoft Active Directory instance to which the file system is joined.

", "ActiveDirectoryError$ActiveDirectoryId": "

The directory ID of the directory that an error pertains to.

", "CreateFileSystemWindowsConfiguration$ActiveDirectoryId": "

The ID for an existing AWS Managed Microsoft Active Directory (AD) instance that the file system should join when it's created.

", - "WindowsFileSystemConfiguration$ActiveDirectoryId": "

The ID for an existing Microsoft Active Directory instance that the file system should join when it's created.

" + "WindowsFileSystemConfiguration$ActiveDirectoryId": "

The ID for an existing AWS Managed Microsoft Active Directory instance that the file system is joined to.

" } }, "DirectoryPassword": { @@ -570,7 +592,7 @@ "base": null, "refs": { "SelfManagedActiveDirectoryAttributes$DnsIps": "

A list of up to two IP addresses of DNS servers or domain controllers in the self-managed AD directory.

", - "SelfManagedActiveDirectoryConfiguration$DnsIps": "

A list of up to two IP addresses of DNS servers or domain controllers in the self-managed AD directory. The IP addresses need to be either in the same VPC CIDR range as the one in which your Amazon FSx file system is being created, or in the private IP version 4 (IPv4) address ranges, as specified in RFC 1918:

", + "SelfManagedActiveDirectoryConfiguration$DnsIps": "

A list of up to two IP addresses of DNS servers or domain controllers in the self-managed AD directory.

", "SelfManagedActiveDirectoryConfigurationUpdates$DnsIps": "

A list of up to two IP addresses of DNS servers or domain controllers in the self-managed AD directory.

" } }, @@ -592,6 +614,7 @@ "refs": { "ActiveDirectoryError$Message": null, "AdministrativeActionFailureDetails$Message": "

Error message providing details about the failed administrative action.

", + "BackupBeingCopied$Message": null, "BackupFailureDetails$Message": "

A message describing the backup creation failure.

", "BackupInProgress$Message": null, "BackupNotFound$Message": null, @@ -605,16 +628,21 @@ "FileSystemFailureDetails$Message": "

A message describing any failures that occurred during file system creation.

", "FileSystemNotFound$Message": null, "IncompatibleParameterError$Message": null, + "IncompatibleRegionForMultiAZ$Message": null, "InternalServerError$Message": null, + "InvalidDestinationKmsKey$Message": null, "InvalidExportPath$Message": null, "InvalidImportPath$Message": null, "InvalidNetworkSettings$Message": null, "InvalidPerUnitStorageThroughput$Message": null, + "InvalidRegion$Message": null, + "InvalidSourceKmsKey$Message": null, "MissingFileSystemConfiguration$Message": null, "NotServiceResourceError$Message": null, "ResourceDoesNotSupportTagging$Message": null, "ResourceNotFound$Message": null, "ServiceLimitExceeded$Message": null, + "SourceBackupUnavailable$Message": null, "UnsupportedOperation$Message": null } }, @@ -742,6 +770,7 @@ "base": null, "refs": { "CompletionReport$Enabled": "

Set Enabled to True to generate a CompletionReport when the task completes. If set to true, then you need to provide a report Scope, Path, and Format. Set Enabled to False if you do not want a CompletionReport generated when the task completes.

", + "CopyBackupRequest$CopyTags": "

A boolean flag indicating whether tags from the source backup should be copied to the backup copy. This value defaults to false.

If you set CopyTags to true and the source backup has existing tags, you can use the Tags parameter to create new tags, provided that the sum of the source backup tags and the new tags doesn't exceed 50. Both sets of tags are merged. If there are tag conflicts (for example, two tags with the same key but different values), the tags created with the Tags parameter take precedence.

", "CreateFileSystemLustreConfiguration$CopyTagsToBackups": "

(Optional) Not available to use with file systems that are linked to a data repository. A boolean flag indicating whether tags for the file system should be copied to backups. The default value is false. If it's set to true, all file system tags are copied to all automatic and user-initiated backups when the user doesn't specify any backup-specific tags. If this value is true, and you specify one or more backup tags, only the specified tags are copied to backups. If you specify one or more tags when creating a user-initiated backup, no tags are copied from the file system, regardless of this value.

For more information, see Working with backups.

", "CreateFileSystemWindowsConfiguration$CopyTagsToBackups": "

A boolean flag indicating whether tags for the file system should be copied to backups. This value defaults to false. If it's set to true, all tags for the file system are copied to all automatic and user-initiated backups where the user doesn't specify tags. If this value is true, and you specify one or more tags, only the specified tags are copied to backups. If you specify one or more tags when creating a user-initiated backup, no tags are copied from the file system, regardless of this value.

", "DeleteFileSystemLustreConfiguration$SkipFinalBackup": "

Set SkipFinalBackup to false if you want to take a final backup of the file system you are deleting. By default, Amazon FSx will not take a final backup on your behalf when the DeleteFileSystem operation is invoked. (Default = true)

", @@ -755,11 +784,21 @@ "refs": { } }, + "IncompatibleRegionForMultiAZ": { + "base": "

Amazon FSx doesn't support Multi-AZ Windows File Server copy backup in the destination Region, so the copied backup can't be restored.

", + "refs": { + } + }, "InternalServerError": { "base": "

A generic error indicating a server-side failure.

", "refs": { } }, + "InvalidDestinationKmsKey": { + "base": "

The AWS Key Management Service (AWS KMS) key of the destination backup is invalid.

", + "refs": { + } + }, "InvalidExportPath": { "base": "

The path provided for data repository export isn't valid.

", "refs": { @@ -780,6 +819,16 @@ "refs": { } }, + "InvalidRegion": { + "base": "

The Region provided for Source Region is invalid or is in a different AWS partition.

", + "refs": { + } + }, + "InvalidSourceKmsKey": { + "base": "

The AWS Key Management Service (AWS KMS) key of the source backup is invalid.

", + "refs": { + } + }, "IpAddress": { "base": null, "refs": { @@ -791,6 +840,8 @@ "base": "

The ID of the AWS Key Management Service (AWS KMS) key used to encrypt the file system's data for Amazon FSx for Windows File Server file systems and Amazon FSx for Lustre PERSISTENT_1 file systems at rest. In either case, if not specified, the Amazon FSx managed key is used. The Amazon FSx for Lustre SCRATCH_1 and SCRATCH_2 file systems are always encrypted at rest using Amazon FSx managed keys. For more information, see Encrypt in the AWS Key Management Service API Reference.

", "refs": { "Backup$KmsKeyId": "

The ID of the AWS Key Management Service (AWS KMS) key used to encrypt the backup of the Amazon FSx file system's data at rest.

", + "CopyBackupRequest$KmsKeyId": null, + "CreateFileSystemFromBackupRequest$KmsKeyId": null, "CreateFileSystemRequest$KmsKeyId": null, "FileSystem$KmsKeyId": "

The ID of the AWS Key Management Service (AWS KMS) key used to encrypt the file system's data for Amazon FSx for Windows File Server file systems and persistent Amazon FSx for Lustre file systems at rest. In either case, if not specified, the Amazon FSx managed key is used. The scratch Amazon FSx for Lustre file systems are always encrypted at rest using Amazon FSx managed keys. For more information, see Encrypt in the AWS Key Management Service API Reference.

" } @@ -852,7 +903,7 @@ "refs": { "CreateFileSystemWindowsConfiguration$ThroughputCapacity": "

The throughput of an Amazon FSx file system, measured in megabytes per second, in 2 to the nth increments, between 2^3 (8) and 2^11 (2048).

", "UpdateFileSystemWindowsConfiguration$ThroughputCapacity": "

Sets the target value for a file system's throughput capacity, in MB/s, that you are updating the file system to. Valid values are 8, 16, 32, 64, 128, 256, 512, 1024, 2048. You cannot make a throughput capacity update request if there is an existing throughput capacity update request in progress. For more information, see Managing Throughput Capacity.

", - "WindowsFileSystemConfiguration$ThroughputCapacity": "

The throughput of an Amazon FSx file system, measured in megabytes per second.

" + "WindowsFileSystemConfiguration$ThroughputCapacity": "

The throughput of the Amazon FSx file system, measured in megabytes per second.

" } }, "MissingFileSystemConfiguration": { @@ -919,6 +970,13 @@ "Backup$ProgressPercent": null } }, + "Region": { + "base": null, + "refs": { + "Backup$SourceBackupRegion": "

The source Region of the backup. Specifies the Region from where this backup is copied.

", + "CopyBackupRequest$SourceRegion": "

The source AWS Region of the backup. Specifies the AWS Region from which the backup is being copied. The source and destination Regions must be in the same AWS partition. If you don't specify a Region, it defaults to the Region where the request is sent from (in-Region copy).

" + } + }, "ReportFormat": { "base": null, "refs": { @@ -940,6 +998,7 @@ "ResourceARN": { "base": "

The Amazon Resource Name (ARN) for a given resource. ARNs uniquely identify AWS resources. We require an ARN when you need to specify a resource unambiguously across all of AWS. For more information, see Amazon Resource Names (ARNs) and AWS Service Namespaces in the AWS General Reference.

", "refs": { + "ActiveDirectoryBackupAttributes$ResourceARN": null, "Backup$ResourceARN": "

The Amazon Resource Name (ARN) for the backup resource.

", "DataRepositoryTask$ResourceARN": null, "FileSystem$ResourceARN": "

The Amazon Resource Name (ARN) for the file system resource.

", @@ -982,7 +1041,7 @@ } }, "SelfManagedActiveDirectoryConfiguration": { - "base": "

The configuration that Amazon FSx uses to join the Windows File Server instance to your self-managed (including on-premises) Microsoft Active Directory (AD) directory.

", + "base": "

The configuration that Amazon FSx uses to join the Windows File Server instance to your self-managed (including on-premises) Microsoft Active Directory (AD) directory. For more information, see Using Amazon FSx with your self-managed Microsoft Active Directory.

", "refs": { "CreateFileSystemWindowsConfiguration$SelfManagedActiveDirectoryConfiguration": null } @@ -1004,6 +1063,17 @@ "refs": { } }, + "SourceBackupId": { + "base": null, + "refs": { + "CopyBackupRequest$SourceBackupId": "

The ID of the source backup. Specifies the ID of the backup that is being copied.

" + } + }, + "SourceBackupUnavailable": { + "base": "

The request was rejected because the lifecycle status of the source backup is not AVAILABLE.

", + "refs": { + } + }, "StartTime": { "base": null, "refs": { @@ -1038,14 +1108,14 @@ "CreateFileSystemWindowsConfiguration$PreferredSubnetId": "

Required when DeploymentType is set to MULTI_AZ_1. This specifies the subnet in which you want the preferred file server to be located. For in-AWS applications, we recommend that you launch your clients in the same Availability Zone (AZ) as your preferred file server to reduce cross-AZ data transfer costs and minimize latency.

", "InvalidNetworkSettings$InvalidSubnetId": null, "SubnetIds$member": null, - "WindowsFileSystemConfiguration$PreferredSubnetId": "

For MULTI_AZ_1 deployment types, it specifies the ID of the subnet where the preferred file server is located. Must be one of the two subnet IDs specified in SubnetIds property. Amazon FSx serves traffic from this subnet except in the event of a failover to the secondary file server.

For SINGLE_AZ_1 and SINGLE_AZ_2 deployment types, this value is the same as that for SubnetIDs. For more information, see Availability and Durability: Single-AZ and Multi-AZ File Systems

" + "WindowsFileSystemConfiguration$PreferredSubnetId": "

For MULTI_AZ_1 deployment types, it specifies the ID of the subnet where the preferred file server is located. Must be one of the two subnet IDs specified in SubnetIds property. Amazon FSx serves traffic from this subnet except in the event of a failover to the secondary file server.

For SINGLE_AZ_1 and SINGLE_AZ_2 deployment types, this value is the same as that for SubnetIDs. For more information, see Availability and durability: Single-AZ and Multi-AZ file systems.

" } }, "SubnetIds": { "base": "

A list of subnet IDs. Currently, you can specify only one subnet ID in a call to the CreateFileSystem operation.

", "refs": { "CreateFileSystemFromBackupRequest$SubnetIds": "

Specifies the IDs of the subnets that the file system will be accessible from. For Windows MULTI_AZ_1 file system deployment types, provide exactly two subnet IDs, one for the preferred file server and one for the standby file server. You specify one of these subnets as the preferred subnet using the WindowsConfiguration > PreferredSubnetID property.

For Windows SINGLE_AZ_1 and SINGLE_AZ_2 deployment types and Lustre file systems, provide exactly one subnet ID. The file server is launched in that subnet's Availability Zone.

", - "CreateFileSystemRequest$SubnetIds": "

Specifies the IDs of the subnets that the file system will be accessible from. For Windows MULTI_AZ_1 file system deployment types, provide exactly two subnet IDs, one for the preferred file server and one for the standby file server. You specify one of these subnets as the preferred subnet using the WindowsConfiguration > PreferredSubnetID property.

For Windows SINGLE_AZ_1 and SINGLE_AZ_2 file system deployment types and Lustre file systems, provide exactly one subnet ID. The file server is launched in that subnet's Availability Zone.

", + "CreateFileSystemRequest$SubnetIds": "

Specifies the IDs of the subnets that the file system will be accessible from. For Windows MULTI_AZ_1 file system deployment types, provide exactly two subnet IDs, one for the preferred file server and one for the standby file server. You specify one of these subnets as the preferred subnet using the WindowsConfiguration > PreferredSubnetID property. For more information, see Availability and durability: Single-AZ and Multi-AZ file systems.

For Windows SINGLE_AZ_1 and SINGLE_AZ_2 file system deployment types and Lustre file systems, provide exactly one subnet ID. The file server is launched in that subnet's Availability Zone.

", "FileSystem$SubnetIds": "

Specifies the IDs of the subnets that the file system is accessible from. For Windows MULTI_AZ_1 file system deployment type, there are two subnet IDs, one for the preferred file server and one for the standby file server. The preferred file server subnet identified in the PreferredSubnetID property. All other file systems have only one subnet ID.

For Lustre file systems, and Single-AZ Windows file systems, this is the ID of the subnet that contains the endpoint for the file system. For MULTI_AZ_1 Windows file systems, the endpoint for the file system is available in the PreferredSubnetID.

" } }, @@ -1094,6 +1164,7 @@ "base": "

A list of Tag values, with a maximum of 50 elements.

", "refs": { "Backup$Tags": "

Tags associated with a particular file system.

", + "CopyBackupRequest$Tags": null, "CreateBackupRequest$Tags": "

(Optional) The tags to apply to the backup at backup creation. The key value of the Name tag appears in the console as the backup name. If you have set CopyTagsToBackups to true, and you specify one or more tags using the CreateBackup action, no existing file system tags are copied from the file system to the backup.

", "CreateDataRepositoryTaskRequest$Tags": null, "CreateFileSystemFromBackupRequest$Tags": "

The tags to be applied to the file system at file system creation. The key value of the Name tag appears in the console as the file system name.

", diff --git a/models/apis/fsx/2018-03-01/examples-1.json b/models/apis/fsx/2018-03-01/examples-1.json index 1f4d652ff2..1993a235ed 100644 --- a/models/apis/fsx/2018-03-01/examples-1.json +++ b/models/apis/fsx/2018-03-01/examples-1.json @@ -1,6 +1,49 @@ { "version": "1.0", "examples": { + "CopyBackup": [ + { + "input": { + "SourceBackupId": "backup-03e3c82e0183b7b6b", + "SourceRegion": "us-east-2" + }, + "output": { + "Backup": { + "BackupId": "backup-0a3364eded1014b28", + "CreationTime": 1617954808.068, + "FileSystem": { + "FileSystemId": "fs-0498eed5fe91001ec", + "FileSystemType": "LUSTRE", + "LustreConfiguration": { + "AutomaticBackupRetentionDays": 0, + "DeploymentType": "PERSISTENT_1", + "PerUnitStorageThroughput": 50, + "WeeklyMaintenanceStartTime": "1:05:00" + }, + "ResourceARN": "arn:aws:fsx:us-east-1:012345678912:file-system/fs-0f5179e395f597e66", + "StorageCapacity": 2400, + "StorageType": "SSD" + }, + "KmsKeyId": "arn:aws:fsx:us-east-1:012345678912:key/d1234e22-543a-12b7-a98f-e12c2b54001a", + "Lifecycle": "COPYING", + "OwnerId": "123456789012", + "ResourceARN": "arn:aws:fsx:us-east-1:012345678912:backup/backup-0a3364eded1014b28", + "Tags": [ + { + "Key": "Name", + "Value": "MyBackup" + } + ], + "Type": "USER_INITIATED" + } + }, + "comments": { + }, + "description": "This operation copies an Amazon FSx backup.", + "id": "to-copy-a-backup-1481847318640", + "title": "To copy a backup" + } + ], "CreateBackup": [ { "input": { diff --git a/models/endpoints/endpoints.json b/models/endpoints/endpoints.json index 74f5f38053..ebeb7028ce 100644 --- a/models/endpoints/endpoints.json +++ b/models/endpoints/endpoints.json @@ -1649,6 +1649,7 @@ "endpoints" : { "ap-northeast-1" : { }, "ap-southeast-2" : { }, + "ca-central-1" : { }, "eu-central-1" : { }, "eu-west-2" : { }, "us-east-1" : { }, @@ -3244,6 +3245,7 @@ "ap-east-1" : { }, "ap-northeast-1" : { }, "ap-northeast-2" : { }, + "ap-northeast-3" : { }, "ap-south-1" : { }, "ap-southeast-1" : { }, "ap-southeast-2" : { }, @@ -3918,6 +3920,13 @@ "us-west-2" : { } } }, + "lookoutequipment" : { + "endpoints" : { + "ap-northeast-2" : { }, + "eu-west-1" : { }, + "us-east-1" : { } + } + }, "lookoutvision" : { "endpoints" : { "ap-northeast-1" : { }, @@ -7569,6 +7578,12 @@ "cn-northwest-1" : { } } }, + "mq" : { + "endpoints" : { + "cn-north-1" : { }, + "cn-northwest-1" : { } + } + }, "neptune" : { "endpoints" : { "cn-northwest-1" : { @@ -8576,6 +8591,27 @@ "us-gov-west-1" : { } } }, + "fms" : { + "defaults" : { + "protocols" : [ "https" ] + }, + "endpoints" : { + "fips-us-gov-east-1" : { + "credentialScope" : { + "region" : "us-gov-east-1" + }, + "hostname" : "fms-fips.us-gov-east-1.amazonaws.com" + }, + "fips-us-gov-west-1" : { + "credentialScope" : { + "region" : "us-gov-west-1" + }, + "hostname" : "fms-fips.us-gov-west-1.amazonaws.com" + }, + "us-gov-east-1" : { }, + "us-gov-west-1" : { } + } + }, "fsx" : { "endpoints" : { "fips-prod-us-gov-east-1" : { diff --git a/service/codebuild/api.go b/service/codebuild/api.go index acd2589f57..c8c16b8606 100644 --- a/service/codebuild/api.go +++ b/service/codebuild/api.go @@ -4898,6 +4898,12 @@ type Build struct { Environment *ProjectEnvironment `locationName:"environment" type:"structure"` // A list of exported environment variables for this build. + // + // Exported environment variables are used in conjunction with AWS CodePipeline + // to export environment variables from the current build stage to subsequent + // stages in the pipeline. For more information, see Working with variables + // (https://docs.aws.amazon.com/codepipeline/latest/userguide/actions-variables.html) + // in the AWS CodePipeline User Guide. ExportedEnvironmentVariables []*ExportedEnvironmentVariable `locationName:"exportedEnvironmentVariables" type:"list"` // An array of ProjectFileSystemLocation objects for a CodeBuild build project. @@ -5213,6 +5219,38 @@ type BuildArtifacts struct { // An identifier for this artifact definition. ArtifactIdentifier *string `locationName:"artifactIdentifier" type:"string"` + // Specifies the access for objects that are uploaded to an Amazon S3 bucket + // that is owned by another account. + // + // By default, only the account that uploads the objects to the bucket has access + // to these objects. This property allows you to give the bucket owner access + // to these objects. + // + // NONE + // + // The bucket owner does not have access to the objects. This is the default. + // + // READ_ONLY + // + // The bucket owner has read only access to the objects. The uploading account + // retains ownership of the objects. + // + // FULL + // + // The bucket owner has full access to the objects. Object ownership is determined + // by the following criteria: + // + // * If the bucket is configured with the Bucket owner preferred setting, + // the bucket owner owns the objects. The uploading account will have object + // access as specified by the bucket's policy. + // + // * Otherwise, the uploading account retains ownership of the objects. + // + // For more information about Amazon S3 object ownership, see Controlling ownership + // of uploaded objects using S3 Object Ownership (https://docs.aws.amazon.com/AmazonS3/latest/userguide/about-object-ownership.html) + // in the Amazon Simple Storage Service User Guide. + BucketOwnerAccess *string `locationName:"bucketOwnerAccess" type:"string" enum:"BucketOwnerAccess"` + // Information that tells you if encryption for build artifacts is disabled. EncryptionDisabled *bool `locationName:"encryptionDisabled" type:"boolean"` @@ -5260,6 +5298,12 @@ func (s *BuildArtifacts) SetArtifactIdentifier(v string) *BuildArtifacts { return s } +// SetBucketOwnerAccess sets the BucketOwnerAccess field's value. +func (s *BuildArtifacts) SetBucketOwnerAccess(v string) *BuildArtifacts { + s.BucketOwnerAccess = &v + return s +} + // SetEncryptionDisabled sets the EncryptionDisabled field's value. func (s *BuildArtifacts) SetEncryptionDisabled(v bool) *BuildArtifacts { s.EncryptionDisabled = &v @@ -7943,19 +7987,25 @@ func (s *EnvironmentVariable) SetValue(v string) *EnvironmentVariable { return s } -// Information about an exported environment variable. +// Contains information about an exported environment variable. +// +// Exported environment variables are used in conjunction with AWS CodePipeline +// to export environment variables from the current build stage to subsequent +// stages in the pipeline. For more information, see Working with variables +// (https://docs.aws.amazon.com/codepipeline/latest/userguide/actions-variables.html) +// in the AWS CodePipeline User Guide. +// +// During a build, the value of a variable is available starting with the install +// phase. It can be updated between the start of the install phase and the end +// of the post_build phase. After the post_build phase ends, the value of exported +// variables cannot change. type ExportedEnvironmentVariable struct { _ struct{} `type:"structure"` - // The name of this exported environment variable. + // The name of the exported environment variable. Name *string `locationName:"name" min:"1" type:"string"` - // The value assigned to this exported environment variable. - // - // During a build, the value of a variable is available starting with the install - // phase. It can be updated between the start of the install phase and the end - // of the post_build phase. After the post_build phase ends, the value of exported - // variables cannot change. + // The value assigned to the exported environment variable. Value *string `locationName:"value" type:"string"` } @@ -10214,6 +10264,38 @@ type ProjectArtifacts struct { // An identifier for this artifact definition. ArtifactIdentifier *string `locationName:"artifactIdentifier" type:"string"` + // Specifies the access for objects that are uploaded to an Amazon S3 bucket + // that is owned by another account. + // + // By default, only the account that uploads the objects to the bucket has access + // to these objects. This property allows you to give the bucket owner access + // to these objects. + // + // NONE + // + // The bucket owner does not have access to the objects. This is the default. + // + // READ_ONLY + // + // The bucket owner has read only access to the objects. The uploading account + // retains ownership of the objects. + // + // FULL + // + // The bucket owner has full access to the objects. Object ownership is determined + // by the following criteria: + // + // * If the bucket is configured with the Bucket owner preferred setting, + // the bucket owner owns the objects. The uploading account will have object + // access as specified by the bucket's policy. + // + // * Otherwise, the uploading account retains ownership of the objects. + // + // For more information about Amazon S3 object ownership, see Controlling ownership + // of uploaded objects using S3 Object Ownership (https://docs.aws.amazon.com/AmazonS3/latest/userguide/about-object-ownership.html) + // in the Amazon Simple Storage Service User Guide. + BucketOwnerAccess *string `locationName:"bucketOwnerAccess" type:"string" enum:"BucketOwnerAccess"` + // Set to true if you do not want your output artifacts encrypted. This option // is valid only if your artifacts type is Amazon S3. If this is set with another // artifacts type, an invalidInputException is thrown. @@ -10356,6 +10438,12 @@ func (s *ProjectArtifacts) SetArtifactIdentifier(v string) *ProjectArtifacts { return s } +// SetBucketOwnerAccess sets the BucketOwnerAccess field's value. +func (s *ProjectArtifacts) SetBucketOwnerAccess(v string) *ProjectArtifacts { + s.BucketOwnerAccess = &v + return s +} + // SetEncryptionDisabled sets the EncryptionDisabled field's value. func (s *ProjectArtifacts) SetEncryptionDisabled(v bool) *ProjectArtifacts { s.EncryptionDisabled = &v @@ -12074,6 +12162,38 @@ func (s *RetryBuildOutput) SetBuild(v *Build) *RetryBuildOutput { type S3LogsConfig struct { _ struct{} `type:"structure"` + // Specifies the access for objects that are uploaded to an Amazon S3 bucket + // that is owned by another account. + // + // By default, only the account that uploads the objects to the bucket has access + // to these objects. This property allows you to give the bucket owner access + // to these objects. + // + // NONE + // + // The bucket owner does not have access to the objects. This is the default. + // + // READ_ONLY + // + // The bucket owner has read only access to the objects. The uploading account + // retains ownership of the objects. + // + // FULL + // + // The bucket owner has full access to the objects. Object ownership is determined + // by the following criteria: + // + // * If the bucket is configured with the Bucket owner preferred setting, + // the bucket owner owns the objects. The uploading account will have object + // access as specified by the bucket's policy. + // + // * Otherwise, the uploading account retains ownership of the objects. + // + // For more information about Amazon S3 object ownership, see Controlling ownership + // of uploaded objects using S3 Object Ownership (https://docs.aws.amazon.com/AmazonS3/latest/userguide/about-object-ownership.html) + // in the Amazon Simple Storage Service User Guide. + BucketOwnerAccess *string `locationName:"bucketOwnerAccess" type:"string" enum:"BucketOwnerAccess"` + // Set to true if you do not want your S3 build log output encrypted. By default // S3 build logs are encrypted. EncryptionDisabled *bool `locationName:"encryptionDisabled" type:"boolean"` @@ -12116,6 +12236,12 @@ func (s *S3LogsConfig) Validate() error { return nil } +// SetBucketOwnerAccess sets the BucketOwnerAccess field's value. +func (s *S3LogsConfig) SetBucketOwnerAccess(v string) *S3LogsConfig { + s.BucketOwnerAccess = &v + return s +} + // SetEncryptionDisabled sets the EncryptionDisabled field's value. func (s *S3LogsConfig) SetEncryptionDisabled(v bool) *S3LogsConfig { s.EncryptionDisabled = &v @@ -14662,6 +14788,56 @@ func AuthType_Values() []string { } } +// Specifies the access for objects that are uploaded to an Amazon S3 bucket +// that is owned by another account. +// +// By default, only the account that uploads the objects to the bucket has access +// to these objects. This property allows you to give the bucket owner access +// to these objects. +// +// NONE +// +// The bucket owner does not have access to the objects. This is the default. +// +// READ_ONLY +// +// The bucket owner has read only access to the objects. The uploading account +// retains ownership of the objects. +// +// FULL +// +// The bucket owner has full access to the objects. Object ownership is determined +// by the following criteria: +// +// * If the bucket is configured with the Bucket owner preferred setting, +// the bucket owner owns the objects. The uploading account will have object +// access as specified by the bucket's policy. +// +// * Otherwise, the uploading account retains ownership of the objects. +// +// For more information about Amazon S3 object ownership, see Controlling ownership +// of uploaded objects using S3 Object Ownership (https://docs.aws.amazon.com/AmazonS3/latest/userguide/about-object-ownership.html) +// in the Amazon Simple Storage Service User Guide. +const ( + // BucketOwnerAccessNone is a BucketOwnerAccess enum value + BucketOwnerAccessNone = "NONE" + + // BucketOwnerAccessReadOnly is a BucketOwnerAccess enum value + BucketOwnerAccessReadOnly = "READ_ONLY" + + // BucketOwnerAccessFull is a BucketOwnerAccess enum value + BucketOwnerAccessFull = "FULL" +) + +// BucketOwnerAccess_Values returns all elements of the BucketOwnerAccess enum +func BucketOwnerAccess_Values() []string { + return []string{ + BucketOwnerAccessNone, + BucketOwnerAccessReadOnly, + BucketOwnerAccessFull, + } +} + const ( // BuildBatchPhaseTypeSubmitted is a BuildBatchPhaseType enum value BuildBatchPhaseTypeSubmitted = "SUBMITTED" diff --git a/service/fsx/api.go b/service/fsx/api.go index 1a4a41c401..855fe9f032 100644 --- a/service/fsx/api.go +++ b/service/fsx/api.go @@ -211,6 +211,144 @@ func (c *FSx) CancelDataRepositoryTaskWithContext(ctx aws.Context, input *Cancel return out, req.Send() } +const opCopyBackup = "CopyBackup" + +// CopyBackupRequest generates a "aws/request.Request" representing the +// client's request for the CopyBackup operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See CopyBackup for more information on using the CopyBackup +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the CopyBackupRequest method. +// req, resp := client.CopyBackupRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/fsx-2018-03-01/CopyBackup +func (c *FSx) CopyBackupRequest(input *CopyBackupInput) (req *request.Request, output *CopyBackupOutput) { + op := &request.Operation{ + Name: opCopyBackup, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &CopyBackupInput{} + } + + output = &CopyBackupOutput{} + req = c.newRequest(op, input, output) + return +} + +// CopyBackup API operation for Amazon FSx. +// +// Copies an existing backup within the same AWS account to another Region (cross-Region +// copy) or within the same Region (in-Region copy). You can have up to five +// backup copy requests in progress to a single destination Region per account. +// +// You can use cross-Region backup copies for cross-region disaster recovery. +// You periodically take backups and copy them to another Region so that in +// the event of a disaster in the primary Region, you can restore from backup +// and recover availability quickly in the other Region. You can make cross-Region +// copies only within your AWS partition. +// +// You can also use backup copies to clone your file data set to another Region +// or within the same Region. +// +// You can use the SourceRegion parameter to specify the AWS Region from which +// the backup will be copied. For example, if you make the call from the us-west-1 +// Region and want to copy a backup from the us-east-2 Region, you specify us-east-2 +// in the SourceRegion parameter to make a cross-Region copy. If you don't specify +// a Region, the backup copy is created in the same Region where the request +// is sent from (in-Region copy). +// +// For more information on creating backup copies, see Copying backups (https://docs.aws.amazon.com/fsx/latest/WindowsGuide/copy-backups.html) +// in the Amazon FSx for Windows User Guide and Copying backups (https://docs.aws.amazon.com/fsx/latest/LustreGuide/copy-backups.html) +// in the Amazon FSx for Lustre User Guide. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon FSx's +// API operation CopyBackup for usage and error information. +// +// Returned Error Types: +// * BadRequest +// A generic error indicating a failure with a client request. +// +// * BackupNotFound +// No Amazon FSx backups were found based upon the supplied parameters. +// +// * ServiceLimitExceeded +// An error indicating that a particular service limit was exceeded. You can +// increase some service limits by contacting AWS Support. +// +// * UnsupportedOperation +// The requested operation is not supported for this resource or API. +// +// * IncompatibleParameterError +// The error returned when a second request is received with the same client +// request token but different parameters settings. A client request token should +// always uniquely identify a single request. +// +// * InternalServerError +// A generic error indicating a server-side failure. +// +// * InvalidSourceKmsKey +// The AWS Key Management Service (AWS KMS) key of the source backup is invalid. +// +// * InvalidDestinationKmsKey +// The AWS Key Management Service (AWS KMS) key of the destination backup is +// invalid. +// +// * InvalidRegion +// The Region provided for Source Region is invalid or is in a different AWS +// partition. +// +// * SourceBackupUnavailable +// The request was rejected because the lifecycle status of the source backup +// is not AVAILABLE. +// +// * IncompatibleRegionForMultiAZ +// Amazon FSx doesn't support Multi-AZ Windows File Server copy backup in the +// destination Region, so the copied backup can't be restored. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/fsx-2018-03-01/CopyBackup +func (c *FSx) CopyBackup(input *CopyBackupInput) (*CopyBackupOutput, error) { + req, out := c.CopyBackupRequest(input) + return out, req.Send() +} + +// CopyBackupWithContext is the same as CopyBackup with the addition of +// the ability to pass a context and additional request options. +// +// See CopyBackup for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *FSx) CopyBackupWithContext(ctx aws.Context, input *CopyBackupInput, opts ...request.Option) (*CopyBackupOutput, error) { + req, out := c.CopyBackupRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opCreateBackup = "CreateBackup" // CreateBackupRequest generates a "aws/request.Request" representing the @@ -825,6 +963,9 @@ func (c *FSx) DeleteBackupRequest(input *DeleteBackupInput) (req *request.Reques // * InternalServerError // A generic error indicating a server-side failure. // +// * BackupBeingCopied +// You can't delete a backup while it's being copied. +// // See also, https://docs.aws.amazon.com/goto/WebAPI/fsx-2018-03-01/DeleteBackup func (c *FSx) DeleteBackup(input *DeleteBackupInput) (*DeleteBackupOutput, error) { req, out := c.DeleteBackupRequest(input) @@ -2129,6 +2270,13 @@ type ActiveDirectoryBackupAttributes struct { // The fully qualified domain name of the self-managed AD directory. DomainName *string `min:"1" type:"string"` + + // The Amazon Resource Name (ARN) for a given resource. ARNs uniquely identify + // AWS resources. We require an ARN when you need to specify a resource unambiguously + // across all of AWS. For more information, see Amazon Resource Names (ARNs) + // and AWS Service Namespaces (https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html) + // in the AWS General Reference. + ResourceARN *string `min:"8" type:"string"` } // String returns the string representation @@ -2153,6 +2301,12 @@ func (s *ActiveDirectoryBackupAttributes) SetDomainName(v string) *ActiveDirecto return s } +// SetResourceARN sets the ResourceARN field's value. +func (s *ActiveDirectoryBackupAttributes) SetResourceARN(v string) *ActiveDirectoryBackupAttributes { + s.ResourceARN = &v + return s +} + // An Active Directory error. type ActiveDirectoryError struct { _ struct{} `type:"structure"` @@ -2384,7 +2538,8 @@ type Alias struct { // * Formatted as a fully-qualified domain name (FQDN), hostname.domain, // for example, accounting.example.com. // - // * Can contain alphanumeric characters and the hyphen (-). + // * Can contain alphanumeric characters, the underscore (_), and the hyphen + // (-). // // * Cannot start or end with a hyphen. // @@ -2533,11 +2688,7 @@ func (s *AssociateFileSystemAliasesOutput) SetAliases(v []*Alias) *AssociateFile return s } -// A backup of an Amazon FSx file system. For more information see: -// -// * Working with backups for Windows file systems (https://docs.aws.amazon.com/fsx/latest/WindowsGuide/using-backups.html) -// -// * Working with backups for Lustre file systems (https://docs.aws.amazon.com/fsx/latest/LustreGuide/using-backups-fsx.html) +// A backup of an Amazon FSx file system. type Backup struct { _ struct{} `type:"structure"` @@ -2580,6 +2731,8 @@ type Backup struct { // * TRANSFERRING - For user-initiated backups on Lustre file systems only; // Amazon FSx is transferring the backup to S3. // + // * COPYING - Amazon FSx is copying the backup. + // // * DELETED - Amazon FSx deleted the backup and it is no longer available. // // * FAILED - Amazon FSx could not complete the backup. @@ -2587,12 +2740,23 @@ type Backup struct { // Lifecycle is a required field Lifecycle *string `type:"string" required:"true" enum:"BackupLifecycle"` + // An AWS account ID. This ID is a 12-digit number that you use to construct + // Amazon Resource Names (ARNs) for resources. + OwnerId *string `min:"12" type:"string"` + // The current percent of progress of an asynchronous task. ProgressPercent *int64 `type:"integer"` // The Amazon Resource Name (ARN) for the backup resource. ResourceARN *string `min:"8" type:"string"` + // The ID of the source backup. Specifies the backup you are copying. + SourceBackupId *string `min:"12" type:"string"` + + // The source Region of the backup. Specifies the Region from where this backup + // is copied. + SourceBackupRegion *string `min:"1" type:"string"` + // Tags associated with a particular file system. Tags []*Tag `min:"1" type:"list"` @@ -2654,6 +2818,12 @@ func (s *Backup) SetLifecycle(v string) *Backup { return s } +// SetOwnerId sets the OwnerId field's value. +func (s *Backup) SetOwnerId(v string) *Backup { + s.OwnerId = &v + return s +} + // SetProgressPercent sets the ProgressPercent field's value. func (s *Backup) SetProgressPercent(v int64) *Backup { s.ProgressPercent = &v @@ -2666,6 +2836,18 @@ func (s *Backup) SetResourceARN(v string) *Backup { return s } +// SetSourceBackupId sets the SourceBackupId field's value. +func (s *Backup) SetSourceBackupId(v string) *Backup { + s.SourceBackupId = &v + return s +} + +// SetSourceBackupRegion sets the SourceBackupRegion field's value. +func (s *Backup) SetSourceBackupRegion(v string) *Backup { + s.SourceBackupRegion = &v + return s +} + // SetTags sets the Tags field's value. func (s *Backup) SetTags(v []*Tag) *Backup { s.Tags = v @@ -2678,6 +2860,66 @@ func (s *Backup) SetType(v string) *Backup { return s } +// You can't delete a backup while it's being copied. +type BackupBeingCopied struct { + _ struct{} `type:"structure"` + RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` + + // The ID of the source backup. Specifies the backup you are copying. + BackupId *string `min:"12" type:"string"` + + // A detailed error message. + Message_ *string `locationName:"Message" min:"1" type:"string"` +} + +// String returns the string representation +func (s BackupBeingCopied) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s BackupBeingCopied) GoString() string { + return s.String() +} + +func newErrorBackupBeingCopied(v protocol.ResponseMetadata) error { + return &BackupBeingCopied{ + RespMetadata: v, + } +} + +// Code returns the exception type name. +func (s *BackupBeingCopied) Code() string { + return "BackupBeingCopied" +} + +// Message returns the exception's message. +func (s *BackupBeingCopied) Message() string { + if s.Message_ != nil { + return *s.Message_ + } + return "" +} + +// OrigErr always returns nil, satisfies awserr.Error interface. +func (s *BackupBeingCopied) OrigErr() error { + return nil +} + +func (s *BackupBeingCopied) Error() string { + return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) +} + +// Status code returns the HTTP status code for the request's response error. +func (s *BackupBeingCopied) StatusCode() int { + return s.RespMetadata.StatusCode +} + +// RequestID returns the service's response RequestID for request. +func (s *BackupBeingCopied) RequestID() string { + return s.RespMetadata.RequestID +} + // If backup creation fails, this structure contains the details of that failure. type BackupFailureDetails struct { _ struct{} `type:"structure"` @@ -3105,9 +3347,160 @@ func (s *CompletionReport) SetPath(v string) *CompletionReport { return s } -// SetScope sets the Scope field's value. -func (s *CompletionReport) SetScope(v string) *CompletionReport { - s.Scope = &v +// SetScope sets the Scope field's value. +func (s *CompletionReport) SetScope(v string) *CompletionReport { + s.Scope = &v + return s +} + +type CopyBackupInput struct { + _ struct{} `type:"structure"` + + // (Optional) An idempotency token for resource creation, in a string of up + // to 64 ASCII characters. This token is automatically filled on your behalf + // when you use the AWS Command Line Interface (AWS CLI) or an AWS SDK. + ClientRequestToken *string `min:"1" type:"string" idempotencyToken:"true"` + + // A boolean flag indicating whether tags from the source backup should be copied + // to the backup copy. This value defaults to false. + // + // If you set CopyTags to true and the source backup has existing tags, you + // can use the Tags parameter to create new tags, provided that the sum of the + // source backup tags and the new tags doesn't exceed 50. Both sets of tags + // are merged. If there are tag conflicts (for example, two tags with the same + // key but different values), the tags created with the Tags parameter take + // precedence. + CopyTags *bool `type:"boolean"` + + // The ID of the AWS Key Management Service (AWS KMS) key used to encrypt the + // file system's data for Amazon FSx for Windows File Server file systems and + // Amazon FSx for Lustre PERSISTENT_1 file systems at rest. In either case, + // if not specified, the Amazon FSx managed key is used. The Amazon FSx for + // Lustre SCRATCH_1 and SCRATCH_2 file systems are always encrypted at rest + // using Amazon FSx managed keys. For more information, see Encrypt (https://docs.aws.amazon.com/kms/latest/APIReference/API_Encrypt.html) + // in the AWS Key Management Service API Reference. + KmsKeyId *string `min:"1" type:"string"` + + // The ID of the source backup. Specifies the ID of the backup that is being + // copied. + // + // SourceBackupId is a required field + SourceBackupId *string `min:"12" type:"string" required:"true"` + + // The source AWS Region of the backup. Specifies the AWS Region from which + // the backup is being copied. The source and destination Regions must be in + // the same AWS partition. If you don't specify a Region, it defaults to the + // Region where the request is sent from (in-Region copy). + SourceRegion *string `min:"1" type:"string"` + + // A list of Tag values, with a maximum of 50 elements. + Tags []*Tag `min:"1" type:"list"` +} + +// String returns the string representation +func (s CopyBackupInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CopyBackupInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CopyBackupInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CopyBackupInput"} + if s.ClientRequestToken != nil && len(*s.ClientRequestToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ClientRequestToken", 1)) + } + if s.KmsKeyId != nil && len(*s.KmsKeyId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("KmsKeyId", 1)) + } + if s.SourceBackupId == nil { + invalidParams.Add(request.NewErrParamRequired("SourceBackupId")) + } + if s.SourceBackupId != nil && len(*s.SourceBackupId) < 12 { + invalidParams.Add(request.NewErrParamMinLen("SourceBackupId", 12)) + } + if s.SourceRegion != nil && len(*s.SourceRegion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("SourceRegion", 1)) + } + if s.Tags != nil && len(s.Tags) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Tags", 1)) + } + if s.Tags != nil { + for i, v := range s.Tags { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetClientRequestToken sets the ClientRequestToken field's value. +func (s *CopyBackupInput) SetClientRequestToken(v string) *CopyBackupInput { + s.ClientRequestToken = &v + return s +} + +// SetCopyTags sets the CopyTags field's value. +func (s *CopyBackupInput) SetCopyTags(v bool) *CopyBackupInput { + s.CopyTags = &v + return s +} + +// SetKmsKeyId sets the KmsKeyId field's value. +func (s *CopyBackupInput) SetKmsKeyId(v string) *CopyBackupInput { + s.KmsKeyId = &v + return s +} + +// SetSourceBackupId sets the SourceBackupId field's value. +func (s *CopyBackupInput) SetSourceBackupId(v string) *CopyBackupInput { + s.SourceBackupId = &v + return s +} + +// SetSourceRegion sets the SourceRegion field's value. +func (s *CopyBackupInput) SetSourceRegion(v string) *CopyBackupInput { + s.SourceRegion = &v + return s +} + +// SetTags sets the Tags field's value. +func (s *CopyBackupInput) SetTags(v []*Tag) *CopyBackupInput { + s.Tags = v + return s +} + +type CopyBackupOutput struct { + _ struct{} `type:"structure"` + + // A backup of an Amazon FSx file system. + Backup *Backup `type:"structure"` +} + +// String returns the string representation +func (s CopyBackupOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s CopyBackupOutput) GoString() string { + return s.String() +} + +// SetBackup sets the Backup field's value. +func (s *CopyBackupOutput) SetBackup(v *Backup) *CopyBackupOutput { + s.Backup = v return s } @@ -3371,8 +3764,7 @@ func (s *CreateDataRepositoryTaskOutput) SetDataRepositoryTask(v *DataRepository type CreateFileSystemFromBackupInput struct { _ struct{} `type:"structure"` - // The ID of the backup. Specifies the backup to use if you're creating a file - // system from an existing backup. + // The ID of the source backup. Specifies the backup you are copying. // // BackupId is a required field BackupId *string `min:"12" type:"string" required:"true"` @@ -3382,6 +3774,15 @@ type CreateFileSystemFromBackupInput struct { // the AWS Command Line Interface (AWS CLI) or an AWS SDK. ClientRequestToken *string `min:"1" type:"string" idempotencyToken:"true"` + // The ID of the AWS Key Management Service (AWS KMS) key used to encrypt the + // file system's data for Amazon FSx for Windows File Server file systems and + // Amazon FSx for Lustre PERSISTENT_1 file systems at rest. In either case, + // if not specified, the Amazon FSx managed key is used. The Amazon FSx for + // Lustre SCRATCH_1 and SCRATCH_2 file systems are always encrypted at rest + // using Amazon FSx managed keys. For more information, see Encrypt (https://docs.aws.amazon.com/kms/latest/APIReference/API_Encrypt.html) + // in the AWS Key Management Service API Reference. + KmsKeyId *string `min:"1" type:"string"` + // The Lustre configuration for the file system being created. LustreConfiguration *CreateFileSystemLustreConfiguration `type:"structure"` @@ -3452,6 +3853,9 @@ func (s *CreateFileSystemFromBackupInput) Validate() error { if s.ClientRequestToken != nil && len(*s.ClientRequestToken) < 1 { invalidParams.Add(request.NewErrParamMinLen("ClientRequestToken", 1)) } + if s.KmsKeyId != nil && len(*s.KmsKeyId) < 1 { + invalidParams.Add(request.NewErrParamMinLen("KmsKeyId", 1)) + } if s.SubnetIds == nil { invalidParams.Add(request.NewErrParamRequired("SubnetIds")) } @@ -3497,6 +3901,12 @@ func (s *CreateFileSystemFromBackupInput) SetClientRequestToken(v string) *Creat return s } +// SetKmsKeyId sets the KmsKeyId field's value. +func (s *CreateFileSystemFromBackupInput) SetKmsKeyId(v string) *CreateFileSystemFromBackupInput { + s.KmsKeyId = &v + return s +} + // SetLustreConfiguration sets the LustreConfiguration field's value. func (s *CreateFileSystemFromBackupInput) SetLustreConfiguration(v *CreateFileSystemLustreConfiguration) *CreateFileSystemFromBackupInput { s.LustreConfiguration = v @@ -3630,7 +4040,8 @@ type CreateFileSystemInput struct { // from. For Windows MULTI_AZ_1 file system deployment types, provide exactly // two subnet IDs, one for the preferred file server and one for the standby // file server. You specify one of these subnets as the preferred subnet using - // the WindowsConfiguration > PreferredSubnetID property. + // the WindowsConfiguration > PreferredSubnetID property. For more information, + // see Availability and durability: Single-AZ and Multi-AZ file systems (https://docs.aws.amazon.com/fsx/latest/WindowsGuide/high-availability-multiAZ.html). // // For Windows SINGLE_AZ_1 and SINGLE_AZ_2 file system deployment types and // Lustre file systems, provide exactly one subnet ID. The file server is launched @@ -4047,7 +4458,8 @@ type CreateFileSystemWindowsConfiguration struct { // * Formatted as a fully-qualified domain name (FQDN), hostname.domain, // for example, accounting.example.com. // - // * Can contain alphanumeric characters and the hyphen (-). + // * Can contain alphanumeric characters, the underscore (_), and the hyphen + // (-). // // * Cannot start or end with a hyphen. // @@ -4103,7 +4515,8 @@ type CreateFileSystemWindowsConfiguration struct { // The configuration that Amazon FSx uses to join the Windows File Server instance // to your self-managed (including on-premises) Microsoft Active Directory (AD) - // directory. + // directory. For more information, see Using Amazon FSx with your self-managed + // Microsoft Active Directory (https://docs.aws.amazon.com/fsx/latest/WindowsGuide/self-managed-AD.html). SelfManagedActiveDirectoryConfiguration *SelfManagedActiveDirectoryConfiguration `type:"structure"` // The throughput of an Amazon FSx file system, measured in megabytes per second, @@ -5341,7 +5754,7 @@ func (s *DescribeBackupsInput) SetNextToken(v string) *DescribeBackupsInput { type DescribeBackupsOutput struct { _ struct{} `type:"structure"` - // Any array of backups. + // An array of backups. Backups []*Backup `type:"list"` // This is present if there are more backups than returned in the response (String). @@ -6201,6 +6614,64 @@ func (s *IncompatibleParameterError) RequestID() string { return s.RespMetadata.RequestID } +// Amazon FSx doesn't support Multi-AZ Windows File Server copy backup in the +// destination Region, so the copied backup can't be restored. +type IncompatibleRegionForMultiAZ struct { + _ struct{} `type:"structure"` + RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` + + // A detailed error message. + Message_ *string `locationName:"Message" min:"1" type:"string"` +} + +// String returns the string representation +func (s IncompatibleRegionForMultiAZ) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s IncompatibleRegionForMultiAZ) GoString() string { + return s.String() +} + +func newErrorIncompatibleRegionForMultiAZ(v protocol.ResponseMetadata) error { + return &IncompatibleRegionForMultiAZ{ + RespMetadata: v, + } +} + +// Code returns the exception type name. +func (s *IncompatibleRegionForMultiAZ) Code() string { + return "IncompatibleRegionForMultiAZ" +} + +// Message returns the exception's message. +func (s *IncompatibleRegionForMultiAZ) Message() string { + if s.Message_ != nil { + return *s.Message_ + } + return "" +} + +// OrigErr always returns nil, satisfies awserr.Error interface. +func (s *IncompatibleRegionForMultiAZ) OrigErr() error { + return nil +} + +func (s *IncompatibleRegionForMultiAZ) Error() string { + return fmt.Sprintf("%s: %s", s.Code(), s.Message()) +} + +// Status code returns the HTTP status code for the request's response error. +func (s *IncompatibleRegionForMultiAZ) StatusCode() int { + return s.RespMetadata.StatusCode +} + +// RequestID returns the service's response RequestID for request. +func (s *IncompatibleRegionForMultiAZ) RequestID() string { + return s.RespMetadata.RequestID +} + // A generic error indicating a server-side failure. type InternalServerError struct { _ struct{} `type:"structure"` @@ -6258,6 +6729,64 @@ func (s *InternalServerError) RequestID() string { return s.RespMetadata.RequestID } +// The AWS Key Management Service (AWS KMS) key of the destination backup is +// invalid. +type InvalidDestinationKmsKey struct { + _ struct{} `type:"structure"` + RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` + + // A detailed error message. + Message_ *string `locationName:"Message" min:"1" type:"string"` +} + +// String returns the string representation +func (s InvalidDestinationKmsKey) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s InvalidDestinationKmsKey) GoString() string { + return s.String() +} + +func newErrorInvalidDestinationKmsKey(v protocol.ResponseMetadata) error { + return &InvalidDestinationKmsKey{ + RespMetadata: v, + } +} + +// Code returns the exception type name. +func (s *InvalidDestinationKmsKey) Code() string { + return "InvalidDestinationKmsKey" +} + +// Message returns the exception's message. +func (s *InvalidDestinationKmsKey) Message() string { + if s.Message_ != nil { + return *s.Message_ + } + return "" +} + +// OrigErr always returns nil, satisfies awserr.Error interface. +func (s *InvalidDestinationKmsKey) OrigErr() error { + return nil +} + +func (s *InvalidDestinationKmsKey) Error() string { + return fmt.Sprintf("%s: %s", s.Code(), s.Message()) +} + +// Status code returns the HTTP status code for the request's response error. +func (s *InvalidDestinationKmsKey) StatusCode() int { + return s.RespMetadata.StatusCode +} + +// RequestID returns the service's response RequestID for request. +func (s *InvalidDestinationKmsKey) RequestID() string { + return s.RespMetadata.RequestID +} + // The path provided for data repository export isn't valid. type InvalidExportPath struct { _ struct{} `type:"structure"` @@ -6504,6 +7033,121 @@ func (s *InvalidPerUnitStorageThroughput) RequestID() string { return s.RespMetadata.RequestID } +// The Region provided for Source Region is invalid or is in a different AWS +// partition. +type InvalidRegion struct { + _ struct{} `type:"structure"` + RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` + + // A detailed error message. + Message_ *string `locationName:"Message" min:"1" type:"string"` +} + +// String returns the string representation +func (s InvalidRegion) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s InvalidRegion) GoString() string { + return s.String() +} + +func newErrorInvalidRegion(v protocol.ResponseMetadata) error { + return &InvalidRegion{ + RespMetadata: v, + } +} + +// Code returns the exception type name. +func (s *InvalidRegion) Code() string { + return "InvalidRegion" +} + +// Message returns the exception's message. +func (s *InvalidRegion) Message() string { + if s.Message_ != nil { + return *s.Message_ + } + return "" +} + +// OrigErr always returns nil, satisfies awserr.Error interface. +func (s *InvalidRegion) OrigErr() error { + return nil +} + +func (s *InvalidRegion) Error() string { + return fmt.Sprintf("%s: %s", s.Code(), s.Message()) +} + +// Status code returns the HTTP status code for the request's response error. +func (s *InvalidRegion) StatusCode() int { + return s.RespMetadata.StatusCode +} + +// RequestID returns the service's response RequestID for request. +func (s *InvalidRegion) RequestID() string { + return s.RespMetadata.RequestID +} + +// The AWS Key Management Service (AWS KMS) key of the source backup is invalid. +type InvalidSourceKmsKey struct { + _ struct{} `type:"structure"` + RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` + + // A detailed error message. + Message_ *string `locationName:"Message" min:"1" type:"string"` +} + +// String returns the string representation +func (s InvalidSourceKmsKey) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s InvalidSourceKmsKey) GoString() string { + return s.String() +} + +func newErrorInvalidSourceKmsKey(v protocol.ResponseMetadata) error { + return &InvalidSourceKmsKey{ + RespMetadata: v, + } +} + +// Code returns the exception type name. +func (s *InvalidSourceKmsKey) Code() string { + return "InvalidSourceKmsKey" +} + +// Message returns the exception's message. +func (s *InvalidSourceKmsKey) Message() string { + if s.Message_ != nil { + return *s.Message_ + } + return "" +} + +// OrigErr always returns nil, satisfies awserr.Error interface. +func (s *InvalidSourceKmsKey) OrigErr() error { + return nil +} + +func (s *InvalidSourceKmsKey) Error() string { + return fmt.Sprintf("%s: %s", s.Code(), s.Message()) +} + +// Status code returns the HTTP status code for the request's response error. +func (s *InvalidSourceKmsKey) StatusCode() int { + return s.RespMetadata.StatusCode +} + +// RequestID returns the service's response RequestID for request. +func (s *InvalidSourceKmsKey) RequestID() string { + return s.RespMetadata.RequestID +} + // The request object for ListTagsForResource operation. type ListTagsForResourceInput struct { _ struct{} `type:"structure"` @@ -7056,21 +7700,13 @@ func (s *SelfManagedActiveDirectoryAttributes) SetUserName(v string) *SelfManage // The configuration that Amazon FSx uses to join the Windows File Server instance // to your self-managed (including on-premises) Microsoft Active Directory (AD) -// directory. +// directory. For more information, see Using Amazon FSx with your self-managed +// Microsoft Active Directory (https://docs.aws.amazon.com/fsx/latest/WindowsGuide/self-managed-AD.html). type SelfManagedActiveDirectoryConfiguration struct { _ struct{} `type:"structure"` // A list of up to two IP addresses of DNS servers or domain controllers in - // the self-managed AD directory. The IP addresses need to be either in the - // same VPC CIDR range as the one in which your Amazon FSx file system is being - // created, or in the private IP version 4 (IPv4) address ranges, as specified - // in RFC 1918 (http://www.faqs.org/rfcs/rfc1918.html): - // - // * 10.0.0.0 - 10.255.255.255 (10/8 prefix) - // - // * 172.16.0.0 - 172.31.255.255 (172.16/12 prefix) - // - // * 192.168.0.0 - 192.168.255.255 (192.168/16 prefix) + // the self-managed AD directory. // // DnsIps is a required field DnsIps []*string `min:"1" type:"list" required:"true"` @@ -7333,6 +7969,67 @@ func (s *ServiceLimitExceeded) RequestID() string { return s.RespMetadata.RequestID } +// The request was rejected because the lifecycle status of the source backup +// is not AVAILABLE. +type SourceBackupUnavailable struct { + _ struct{} `type:"structure"` + RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` + + // The ID of the source backup. Specifies the backup you are copying. + BackupId *string `min:"12" type:"string"` + + // A detailed error message. + Message_ *string `locationName:"Message" min:"1" type:"string"` +} + +// String returns the string representation +func (s SourceBackupUnavailable) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s SourceBackupUnavailable) GoString() string { + return s.String() +} + +func newErrorSourceBackupUnavailable(v protocol.ResponseMetadata) error { + return &SourceBackupUnavailable{ + RespMetadata: v, + } +} + +// Code returns the exception type name. +func (s *SourceBackupUnavailable) Code() string { + return "SourceBackupUnavailable" +} + +// Message returns the exception's message. +func (s *SourceBackupUnavailable) Message() string { + if s.Message_ != nil { + return *s.Message_ + } + return "" +} + +// OrigErr always returns nil, satisfies awserr.Error interface. +func (s *SourceBackupUnavailable) OrigErr() error { + return nil +} + +func (s *SourceBackupUnavailable) Error() string { + return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) +} + +// Status code returns the HTTP status code for the request's response error. +func (s *SourceBackupUnavailable) StatusCode() int { + return s.RespMetadata.StatusCode +} + +// RequestID returns the service's response RequestID for request. +func (s *SourceBackupUnavailable) RequestID() string { + return s.RespMetadata.RequestID +} + // Specifies a key-value pair for a resource tag. type Tag struct { _ struct{} `type:"structure"` @@ -7953,8 +8650,8 @@ func (s *UpdateFileSystemWindowsConfiguration) SetWeeklyMaintenanceStartTime(v s type WindowsFileSystemConfiguration struct { _ struct{} `type:"structure"` - // The ID for an existing Microsoft Active Directory instance that the file - // system should join when it's created. + // The ID for an existing AWS Managed Microsoft Active Directory instance that + // the file system is joined to. ActiveDirectoryId *string `min:"12" type:"string"` // An array of one or more DNS aliases that are currently associated with the @@ -8021,8 +8718,8 @@ type WindowsFileSystemConfiguration struct { // in the event of a failover to the secondary file server. // // For SINGLE_AZ_1 and SINGLE_AZ_2 deployment types, this value is the same - // as that for SubnetIDs. For more information, see Availability and Durability: - // Single-AZ and Multi-AZ File Systems (https://docs.aws.amazon.com/fsx/latest/WindowsGuide/high-availability-multiAZ.html#single-multi-az-resources) + // as that for SubnetIDs. For more information, see Availability and durability: + // Single-AZ and Multi-AZ file systems (https://docs.aws.amazon.com/fsx/latest/WindowsGuide/high-availability-multiAZ.html#single-multi-az-resources). PreferredSubnetId *string `min:"15" type:"string"` // For MULTI_AZ_1 deployment types, use this endpoint when performing administrative @@ -8039,7 +8736,7 @@ type WindowsFileSystemConfiguration struct { // to which the Windows File Server instance is joined. SelfManagedActiveDirectoryConfiguration *SelfManagedActiveDirectoryAttributes `type:"structure"` - // The throughput of an Amazon FSx file system, measured in megabytes per second. + // The throughput of the Amazon FSx file system, measured in megabytes per second. ThroughputCapacity *int64 `min:"8" type:"integer"` // The preferred start time to perform weekly maintenance, formatted d:HH:MM @@ -8274,6 +8971,8 @@ func AutoImportPolicyType_Values() []string { // * TRANSFERRING - For user-initiated backups on Lustre file systems only; // Amazon FSx is backing up the file system. // +// * COPYING - Amazon FSx is copying the backup. +// // * DELETED - Amazon FSx deleted the backup and it is no longer available. // // * FAILED - Amazon FSx could not complete the backup. @@ -8295,6 +8994,9 @@ const ( // BackupLifecyclePending is a BackupLifecycle enum value BackupLifecyclePending = "PENDING" + + // BackupLifecycleCopying is a BackupLifecycle enum value + BackupLifecycleCopying = "COPYING" ) // BackupLifecycle_Values returns all elements of the BackupLifecycle enum @@ -8306,6 +9008,7 @@ func BackupLifecycle_Values() []string { BackupLifecycleDeleted, BackupLifecycleFailed, BackupLifecyclePending, + BackupLifecycleCopying, } } @@ -8582,6 +9285,12 @@ const ( // ServiceLimitTotalUserInitiatedBackups is a ServiceLimit enum value ServiceLimitTotalUserInitiatedBackups = "TOTAL_USER_INITIATED_BACKUPS" + + // ServiceLimitTotalUserTags is a ServiceLimit enum value + ServiceLimitTotalUserTags = "TOTAL_USER_TAGS" + + // ServiceLimitTotalInProgressCopyBackups is a ServiceLimit enum value + ServiceLimitTotalInProgressCopyBackups = "TOTAL_IN_PROGRESS_COPY_BACKUPS" ) // ServiceLimit_Values returns all elements of the ServiceLimit enum @@ -8591,6 +9300,8 @@ func ServiceLimit_Values() []string { ServiceLimitTotalThroughputCapacity, ServiceLimitTotalStorage, ServiceLimitTotalUserInitiatedBackups, + ServiceLimitTotalUserTags, + ServiceLimitTotalInProgressCopyBackups, } } diff --git a/service/fsx/errors.go b/service/fsx/errors.go index a827e7345c..3467dcaf26 100644 --- a/service/fsx/errors.go +++ b/service/fsx/errors.go @@ -14,6 +14,12 @@ const ( // An Active Directory error. ErrCodeActiveDirectoryError = "ActiveDirectoryError" + // ErrCodeBackupBeingCopied for service response error code + // "BackupBeingCopied". + // + // You can't delete a backup while it's being copied. + ErrCodeBackupBeingCopied = "BackupBeingCopied" + // ErrCodeBackupInProgress for service response error code // "BackupInProgress". // @@ -73,12 +79,26 @@ const ( // always uniquely identify a single request. ErrCodeIncompatibleParameterError = "IncompatibleParameterError" + // ErrCodeIncompatibleRegionForMultiAZ for service response error code + // "IncompatibleRegionForMultiAZ". + // + // Amazon FSx doesn't support Multi-AZ Windows File Server copy backup in the + // destination Region, so the copied backup can't be restored. + ErrCodeIncompatibleRegionForMultiAZ = "IncompatibleRegionForMultiAZ" + // ErrCodeInternalServerError for service response error code // "InternalServerError". // // A generic error indicating a server-side failure. ErrCodeInternalServerError = "InternalServerError" + // ErrCodeInvalidDestinationKmsKey for service response error code + // "InvalidDestinationKmsKey". + // + // The AWS Key Management Service (AWS KMS) key of the destination backup is + // invalid. + ErrCodeInvalidDestinationKmsKey = "InvalidDestinationKmsKey" + // ErrCodeInvalidExportPath for service response error code // "InvalidExportPath". // @@ -109,6 +129,19 @@ const ( // your file system again, using a valid value. ErrCodeInvalidPerUnitStorageThroughput = "InvalidPerUnitStorageThroughput" + // ErrCodeInvalidRegion for service response error code + // "InvalidRegion". + // + // The Region provided for Source Region is invalid or is in a different AWS + // partition. + ErrCodeInvalidRegion = "InvalidRegion" + + // ErrCodeInvalidSourceKmsKey for service response error code + // "InvalidSourceKmsKey". + // + // The AWS Key Management Service (AWS KMS) key of the source backup is invalid. + ErrCodeInvalidSourceKmsKey = "InvalidSourceKmsKey" + // ErrCodeMissingFileSystemConfiguration for service response error code // "MissingFileSystemConfiguration". // @@ -141,6 +174,13 @@ const ( // increase some service limits by contacting AWS Support. ErrCodeServiceLimitExceeded = "ServiceLimitExceeded" + // ErrCodeSourceBackupUnavailable for service response error code + // "SourceBackupUnavailable". + // + // The request was rejected because the lifecycle status of the source backup + // is not AVAILABLE. + ErrCodeSourceBackupUnavailable = "SourceBackupUnavailable" + // ErrCodeUnsupportedOperation for service response error code // "UnsupportedOperation". // @@ -150,6 +190,7 @@ const ( var exceptionFromCode = map[string]func(protocol.ResponseMetadata) error{ "ActiveDirectoryError": newErrorActiveDirectoryError, + "BackupBeingCopied": newErrorBackupBeingCopied, "BackupInProgress": newErrorBackupInProgress, "BackupNotFound": newErrorBackupNotFound, "BackupRestoring": newErrorBackupRestoring, @@ -159,15 +200,20 @@ var exceptionFromCode = map[string]func(protocol.ResponseMetadata) error{ "DataRepositoryTaskNotFound": newErrorDataRepositoryTaskNotFound, "FileSystemNotFound": newErrorFileSystemNotFound, "IncompatibleParameterError": newErrorIncompatibleParameterError, + "IncompatibleRegionForMultiAZ": newErrorIncompatibleRegionForMultiAZ, "InternalServerError": newErrorInternalServerError, + "InvalidDestinationKmsKey": newErrorInvalidDestinationKmsKey, "InvalidExportPath": newErrorInvalidExportPath, "InvalidImportPath": newErrorInvalidImportPath, "InvalidNetworkSettings": newErrorInvalidNetworkSettings, "InvalidPerUnitStorageThroughput": newErrorInvalidPerUnitStorageThroughput, + "InvalidRegion": newErrorInvalidRegion, + "InvalidSourceKmsKey": newErrorInvalidSourceKmsKey, "MissingFileSystemConfiguration": newErrorMissingFileSystemConfiguration, "NotServiceResourceError": newErrorNotServiceResourceError, "ResourceDoesNotSupportTagging": newErrorResourceDoesNotSupportTagging, "ResourceNotFound": newErrorResourceNotFound, "ServiceLimitExceeded": newErrorServiceLimitExceeded, + "SourceBackupUnavailable": newErrorSourceBackupUnavailable, "UnsupportedOperation": newErrorUnsupportedOperation, } diff --git a/service/fsx/examples_test.go b/service/fsx/examples_test.go index 633bccd6da..0aaf467970 100644 --- a/service/fsx/examples_test.go +++ b/service/fsx/examples_test.go @@ -25,6 +25,56 @@ func parseTime(layout, value string) *time.Time { return &t } +// To copy a backup +// +// This operation copies an Amazon FSx backup. +func ExampleFSx_CopyBackup_shared00() { + svc := fsx.New(session.New()) + input := &fsx.CopyBackupInput{ + SourceBackupId: aws.String("backup-03e3c82e0183b7b6b"), + SourceRegion: aws.String("us-east-2"), + } + + result, err := svc.CopyBackup(input) + if err != nil { + if aerr, ok := err.(awserr.Error); ok { + switch aerr.Code() { + case fsx.ErrCodeBadRequest: + fmt.Println(fsx.ErrCodeBadRequest, aerr.Error()) + case fsx.ErrCodeBackupNotFound: + fmt.Println(fsx.ErrCodeBackupNotFound, aerr.Error()) + case fsx.ErrCodeServiceLimitExceeded: + fmt.Println(fsx.ErrCodeServiceLimitExceeded, aerr.Error()) + case fsx.ErrCodeUnsupportedOperation: + fmt.Println(fsx.ErrCodeUnsupportedOperation, aerr.Error()) + case fsx.ErrCodeIncompatibleParameterError: + fmt.Println(fsx.ErrCodeIncompatibleParameterError, aerr.Error()) + case fsx.ErrCodeInternalServerError: + fmt.Println(fsx.ErrCodeInternalServerError, aerr.Error()) + case fsx.ErrCodeInvalidSourceKmsKey: + fmt.Println(fsx.ErrCodeInvalidSourceKmsKey, aerr.Error()) + case fsx.ErrCodeInvalidDestinationKmsKey: + fmt.Println(fsx.ErrCodeInvalidDestinationKmsKey, aerr.Error()) + case fsx.ErrCodeInvalidRegion: + fmt.Println(fsx.ErrCodeInvalidRegion, aerr.Error()) + case fsx.ErrCodeSourceBackupUnavailable: + fmt.Println(fsx.ErrCodeSourceBackupUnavailable, aerr.Error()) + case fsx.ErrCodeIncompatibleRegionForMultiAZ: + fmt.Println(fsx.ErrCodeIncompatibleRegionForMultiAZ, aerr.Error()) + default: + fmt.Println(aerr.Error()) + } + } else { + // Print the error, cast err to awserr.Error to get the Code and + // Message from an error. + fmt.Println(err.Error()) + } + return + } + + fmt.Println(result) +} + // To create a new backup // // This operation creates a new backup. @@ -231,6 +281,8 @@ func ExampleFSx_DeleteBackup_shared00() { fmt.Println(fsx.ErrCodeIncompatibleParameterError, aerr.Error()) case fsx.ErrCodeInternalServerError: fmt.Println(fsx.ErrCodeInternalServerError, aerr.Error()) + case fsx.ErrCodeBackupBeingCopied: + fmt.Println(fsx.ErrCodeBackupBeingCopied, aerr.Error()) default: fmt.Println(aerr.Error()) } diff --git a/service/fsx/fsxiface/interface.go b/service/fsx/fsxiface/interface.go index 5879988ebe..c1a547824b 100644 --- a/service/fsx/fsxiface/interface.go +++ b/service/fsx/fsxiface/interface.go @@ -68,6 +68,10 @@ type FSxAPI interface { CancelDataRepositoryTaskWithContext(aws.Context, *fsx.CancelDataRepositoryTaskInput, ...request.Option) (*fsx.CancelDataRepositoryTaskOutput, error) CancelDataRepositoryTaskRequest(*fsx.CancelDataRepositoryTaskInput) (*request.Request, *fsx.CancelDataRepositoryTaskOutput) + CopyBackup(*fsx.CopyBackupInput) (*fsx.CopyBackupOutput, error) + CopyBackupWithContext(aws.Context, *fsx.CopyBackupInput, ...request.Option) (*fsx.CopyBackupOutput, error) + CopyBackupRequest(*fsx.CopyBackupInput) (*request.Request, *fsx.CopyBackupOutput) + CreateBackup(*fsx.CreateBackupInput) (*fsx.CreateBackupOutput, error) CreateBackupWithContext(aws.Context, *fsx.CreateBackupInput, ...request.Option) (*fsx.CreateBackupOutput, error) CreateBackupRequest(*fsx.CreateBackupInput) (*request.Request, *fsx.CreateBackupOutput)