import { Command as $Command } from "@smithy/core/client"; import type { MetadataBearer as __MetadataBearer } from "@smithy/types"; import type { RestoreDBClusterFromS3Message, RestoreDBClusterFromS3Result } from "../models/models_1"; import type { RDSClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../RDSClient"; /** * @public */ export type { __MetadataBearer }; export { $Command }; /** * @public * * The input for {@link RestoreDBClusterFromS3Command}. */ export interface RestoreDBClusterFromS3CommandInput extends RestoreDBClusterFromS3Message { } /** * @public * * The output of {@link RestoreDBClusterFromS3Command}. */ export interface RestoreDBClusterFromS3CommandOutput extends RestoreDBClusterFromS3Result, __MetadataBearer { } declare const RestoreDBClusterFromS3Command_base: { new (input: RestoreDBClusterFromS3CommandInput): import("@smithy/core/client").CommandImpl; new (input: RestoreDBClusterFromS3CommandInput): import("@smithy/core/client").CommandImpl; getEndpointParameterInstructions(): { [x: string]: unknown; }; }; /** *

Creates an Amazon Aurora DB cluster from MySQL data stored in an Amazon S3 bucket. Amazon RDS must be authorized to access the Amazon S3 bucket and the data must be created using the Percona XtraBackup utility as described in Migrating Data from MySQL by Using an Amazon S3 Bucket in the Amazon Aurora User Guide.

This operation only restores the DB cluster, not the DB instances for that DB cluster. You must invoke the CreateDBInstance operation to create DB instances for the restored DB cluster, specifying the identifier of the restored DB cluster in DBClusterIdentifier. You can create DB instances only after the RestoreDBClusterFromS3 operation has completed and the DB cluster is available.

For more information on Amazon Aurora, see What is Amazon Aurora? in the Amazon Aurora User Guide.

This operation only applies to Aurora DB clusters. The source DB engine must be MySQL.

* @example * Use a bare-bones client and the command you need to make an API call. * ```javascript * import { RDSClient, RestoreDBClusterFromS3Command } from "@aws-sdk/client-rds"; // ES Modules import * // const { RDSClient, RestoreDBClusterFromS3Command } = require("@aws-sdk/client-rds"); // CommonJS import * // import type { RDSClientConfig } from "@aws-sdk/client-rds"; * const config = {}; // type is RDSClientConfig * const client = new RDSClient(config); * const input = { // RestoreDBClusterFromS3Message * AvailabilityZones: [ // AvailabilityZones * "STRING_VALUE", * ], * BackupRetentionPeriod: Number("int"), * CharacterSetName: "STRING_VALUE", * DatabaseName: "STRING_VALUE", * DBClusterIdentifier: "STRING_VALUE", // required * DBClusterParameterGroupName: "STRING_VALUE", * VpcSecurityGroupIds: [ // VpcSecurityGroupIdList * "STRING_VALUE", * ], * DBSubnetGroupName: "STRING_VALUE", * Engine: "STRING_VALUE", // required * EngineVersion: "STRING_VALUE", * Port: Number("int"), * MasterUsername: "STRING_VALUE", // required * MasterUserPassword: "STRING_VALUE", * OptionGroupName: "STRING_VALUE", * PreferredBackupWindow: "STRING_VALUE", * PreferredMaintenanceWindow: "STRING_VALUE", * Tags: [ // TagList * { // Tag * Key: "STRING_VALUE", * Value: "STRING_VALUE", * }, * ], * StorageEncrypted: true || false, * KmsKeyId: "STRING_VALUE", * EnableIAMDatabaseAuthentication: true || false, * SourceEngine: "STRING_VALUE", // required * SourceEngineVersion: "STRING_VALUE", // required * S3BucketName: "STRING_VALUE", // required * S3Prefix: "STRING_VALUE", * S3IngestionRoleArn: "STRING_VALUE", // required * BacktrackWindow: Number("long"), * EnableCloudwatchLogsExports: [ // LogTypeList * "STRING_VALUE", * ], * DeletionProtection: true || false, * CopyTagsToSnapshot: true || false, * Domain: "STRING_VALUE", * DomainIAMRoleName: "STRING_VALUE", * StorageType: "STRING_VALUE", * NetworkType: "STRING_VALUE", * ServerlessV2ScalingConfiguration: { // ServerlessV2ScalingConfiguration * MinCapacity: Number("double"), * MaxCapacity: Number("double"), * SecondsUntilAutoPause: Number("int"), * }, * ManageMasterUserPassword: true || false, * MasterUserSecretKmsKeyId: "STRING_VALUE", * EngineLifecycleSupport: "STRING_VALUE", * TagSpecifications: [ // TagSpecificationList * { // TagSpecification * ResourceType: "STRING_VALUE", * Tags: [ * { * Key: "STRING_VALUE", * Value: "STRING_VALUE", * }, * ], * }, * ], * }; * const command = new RestoreDBClusterFromS3Command(input); * const response = await client.send(command); * // { // RestoreDBClusterFromS3Result * // DBCluster: { // DBCluster * // AllocatedStorage: Number("int"), * // AvailabilityZones: [ // AvailabilityZones * // "STRING_VALUE", * // ], * // BackupRetentionPeriod: Number("int"), * // CharacterSetName: "STRING_VALUE", * // DatabaseName: "STRING_VALUE", * // DBClusterIdentifier: "STRING_VALUE", * // DBClusterParameterGroup: "STRING_VALUE", * // DBSubnetGroup: "STRING_VALUE", * // Status: "STRING_VALUE", * // PercentProgress: "STRING_VALUE", * // EarliestRestorableTime: new Date("TIMESTAMP"), * // Endpoint: "STRING_VALUE", * // ReaderEndpoint: "STRING_VALUE", * // CustomEndpoints: [ // StringList * // "STRING_VALUE", * // ], * // MultiAZ: true || false, * // Engine: "STRING_VALUE", * // EngineVersion: "STRING_VALUE", * // LatestRestorableTime: new Date("TIMESTAMP"), * // Port: Number("int"), * // MasterUsername: "STRING_VALUE", * // DBClusterOptionGroupMemberships: [ // DBClusterOptionGroupMemberships * // { // DBClusterOptionGroupStatus * // DBClusterOptionGroupName: "STRING_VALUE", * // Status: "STRING_VALUE", * // }, * // ], * // PreferredBackupWindow: "STRING_VALUE", * // PreferredMaintenanceWindow: "STRING_VALUE", * // UpgradeRolloutOrder: "first" || "second" || "last", * // ReplicationSourceIdentifier: "STRING_VALUE", * // ReadReplicaIdentifiers: [ // ReadReplicaIdentifierList * // "STRING_VALUE", * // ], * // StatusInfos: [ // DBClusterStatusInfoList * // { // DBClusterStatusInfo * // StatusType: "STRING_VALUE", * // Normal: true || false, * // Status: "STRING_VALUE", * // Message: "STRING_VALUE", * // }, * // ], * // DBClusterMembers: [ // DBClusterMemberList * // { // DBClusterMember * // DBInstanceIdentifier: "STRING_VALUE", * // IsClusterWriter: true || false, * // DBClusterParameterGroupStatus: "STRING_VALUE", * // PromotionTier: Number("int"), * // }, * // ], * // VpcSecurityGroups: [ // VpcSecurityGroupMembershipList * // { // VpcSecurityGroupMembership * // VpcSecurityGroupId: "STRING_VALUE", * // Status: "STRING_VALUE", * // }, * // ], * // HostedZoneId: "STRING_VALUE", * // StorageEncrypted: true || false, * // StorageEncryptionType: "none" || "sse-kms" || "sse-rds", * // KmsKeyId: "STRING_VALUE", * // DbClusterResourceId: "STRING_VALUE", * // DBClusterArn: "STRING_VALUE", * // AssociatedRoles: [ // DBClusterRoles * // { // DBClusterRole * // RoleArn: "STRING_VALUE", * // Status: "STRING_VALUE", * // FeatureName: "STRING_VALUE", * // }, * // ], * // IAMDatabaseAuthenticationEnabled: true || false, * // CloneGroupId: "STRING_VALUE", * // ClusterCreateTime: new Date("TIMESTAMP"), * // EarliestBacktrackTime: new Date("TIMESTAMP"), * // BacktrackWindow: Number("long"), * // BacktrackConsumedChangeRecords: Number("long"), * // EnabledCloudwatchLogsExports: [ // LogTypeList * // "STRING_VALUE", * // ], * // Capacity: Number("int"), * // PendingModifiedValues: { // ClusterPendingModifiedValues * // PendingCloudwatchLogsExports: { // PendingCloudwatchLogsExports * // LogTypesToEnable: [ * // "STRING_VALUE", * // ], * // LogTypesToDisable: [ * // "STRING_VALUE", * // ], * // }, * // DBClusterIdentifier: "STRING_VALUE", * // MasterUserPassword: "STRING_VALUE", * // IAMDatabaseAuthenticationEnabled: true || false, * // EngineVersion: "STRING_VALUE", * // BackupRetentionPeriod: Number("int"), * // StorageType: "STRING_VALUE", * // AllocatedStorage: Number("int"), * // RdsCustomClusterConfiguration: { // RdsCustomClusterConfiguration * // InterconnectSubnetId: "STRING_VALUE", * // TransitGatewayMulticastDomainId: "STRING_VALUE", * // ReplicaMode: "open-read-only" || "mounted", * // }, * // Iops: Number("int"), * // CertificateDetails: { // CertificateDetails * // CAIdentifier: "STRING_VALUE", * // ValidTill: new Date("TIMESTAMP"), * // }, * // }, * // EngineMode: "STRING_VALUE", * // ScalingConfigurationInfo: { // ScalingConfigurationInfo * // MinCapacity: Number("int"), * // MaxCapacity: Number("int"), * // AutoPause: true || false, * // SecondsUntilAutoPause: Number("int"), * // TimeoutAction: "STRING_VALUE", * // SecondsBeforeTimeout: Number("int"), * // }, * // RdsCustomClusterConfiguration: { * // InterconnectSubnetId: "STRING_VALUE", * // TransitGatewayMulticastDomainId: "STRING_VALUE", * // ReplicaMode: "open-read-only" || "mounted", * // }, * // DBClusterInstanceClass: "STRING_VALUE", * // StorageType: "STRING_VALUE", * // Iops: Number("int"), * // StorageThroughput: Number("int"), * // IOOptimizedNextAllowedModificationTime: new Date("TIMESTAMP"), * // PubliclyAccessible: true || false, * // AutoMinorVersionUpgrade: true || false, * // DeletionProtection: true || false, * // HttpEndpointEnabled: true || false, * // ActivityStreamMode: "sync" || "async", * // ActivityStreamStatus: "stopped" || "starting" || "started" || "stopping", * // ActivityStreamKmsKeyId: "STRING_VALUE", * // ActivityStreamKinesisStreamName: "STRING_VALUE", * // CopyTagsToSnapshot: true || false, * // CrossAccountClone: true || false, * // DomainMemberships: [ // DomainMembershipList * // { // DomainMembership * // Domain: "STRING_VALUE", * // Status: "STRING_VALUE", * // FQDN: "STRING_VALUE", * // IAMRoleName: "STRING_VALUE", * // OU: "STRING_VALUE", * // AuthSecretArn: "STRING_VALUE", * // DnsIps: [ * // "STRING_VALUE", * // ], * // }, * // ], * // TagList: [ // TagList * // { // Tag * // Key: "STRING_VALUE", * // Value: "STRING_VALUE", * // }, * // ], * // GlobalClusterIdentifier: "STRING_VALUE", * // GlobalWriteForwardingStatus: "enabled" || "disabled" || "enabling" || "disabling" || "unknown", * // GlobalWriteForwardingRequested: true || false, * // NetworkType: "STRING_VALUE", * // AutomaticRestartTime: new Date("TIMESTAMP"), * // ServerlessV2ScalingConfiguration: { // ServerlessV2ScalingConfigurationInfo * // MinCapacity: Number("double"), * // MaxCapacity: Number("double"), * // SecondsUntilAutoPause: Number("int"), * // }, * // ServerlessV2PlatformVersion: "STRING_VALUE", * // MonitoringInterval: Number("int"), * // MonitoringRoleArn: "STRING_VALUE", * // DatabaseInsightsMode: "standard" || "advanced", * // PerformanceInsightsEnabled: true || false, * // PerformanceInsightsKMSKeyId: "STRING_VALUE", * // PerformanceInsightsRetentionPeriod: Number("int"), * // DBSystemId: "STRING_VALUE", * // MasterUserSecret: { // MasterUserSecret * // SecretArn: "STRING_VALUE", * // SecretStatus: "STRING_VALUE", * // KmsKeyId: "STRING_VALUE", * // }, * // LocalWriteForwardingStatus: "enabled" || "disabled" || "enabling" || "disabling" || "requested", * // AwsBackupRecoveryPointArn: "STRING_VALUE", * // LimitlessDatabase: { // LimitlessDatabase * // Status: "active" || "not-in-use" || "enabled" || "disabled" || "enabling" || "disabling" || "modifying-max-capacity" || "error", * // MinRequiredACU: Number("double"), * // }, * // ClusterScalabilityType: "standard" || "limitless", * // CertificateDetails: { * // CAIdentifier: "STRING_VALUE", * // ValidTill: new Date("TIMESTAMP"), * // }, * // EngineLifecycleSupport: "STRING_VALUE", * // VPCNetworkingEnabled: true || false, * // InternetAccessGatewayEnabled: true || false, * // }, * // }; * * ``` * * @param RestoreDBClusterFromS3CommandInput - {@link RestoreDBClusterFromS3CommandInput} * @returns {@link RestoreDBClusterFromS3CommandOutput} * @see {@link RestoreDBClusterFromS3CommandInput} for command's `input` shape. * @see {@link RestoreDBClusterFromS3CommandOutput} for command's `response` shape. * @see {@link RDSClientResolvedConfig | config} for RDSClient's `config` shape. * * @throws {@link DBClusterAlreadyExistsFault} (client fault) *

The user already has a DB cluster with the given identifier.

* * @throws {@link DBClusterNotFoundFault} (client fault) *

DBClusterIdentifier doesn't refer to an existing DB cluster.

* * @throws {@link DBClusterParameterGroupNotFoundFault} (client fault) *

DBClusterParameterGroupName doesn't refer to an existing DB cluster parameter group.

* * @throws {@link DBClusterQuotaExceededFault} (client fault) *

The user attempted to create a new DB cluster and the user has already reached the maximum allowed DB cluster quota.

* * @throws {@link DBSubnetGroupNotFoundFault} (client fault) *

DBSubnetGroupName doesn't refer to an existing DB subnet group.

* * @throws {@link DomainNotFoundFault} (client fault) *

Domain doesn't refer to an existing Active Directory domain.

* * @throws {@link InsufficientStorageClusterCapacityFault} (client fault) *

There is insufficient storage available for the current action. You might be able to resolve this error by updating your subnet group to use different Availability Zones that have more storage available.

* * @throws {@link InvalidDBClusterStateFault} (client fault) *

The requested operation can't be performed while the cluster is in this state.

* * @throws {@link InvalidDBSubnetGroupStateFault} (client fault) *

The DB subnet group cannot be deleted because it's in use.

* * @throws {@link InvalidS3BucketFault} (client fault) *

The specified Amazon S3 bucket name can't be found or Amazon RDS isn't authorized to access the specified Amazon S3 bucket. Verify the SourceS3BucketName and S3IngestionRoleArn values and try again.

* * @throws {@link InvalidSubnet} (client fault) *

The requested subnet is invalid, or multiple subnets were requested that are not all in a common VPC.

* * @throws {@link InvalidVPCNetworkStateFault} (client fault) *

The DB subnet group doesn't cover all Availability Zones after it's created because of users' change.

* * @throws {@link KMSKeyNotAccessibleFault} (client fault) *

An error occurred accessing an Amazon Web Services KMS key.

* * @throws {@link NetworkTypeNotSupported} (client fault) *

The network type is invalid for the DB instance. Valid nework type values are IPV4 and DUAL.

* * @throws {@link StorageQuotaExceededFault} (client fault) *

The request would result in the user exceeding the allowed amount of storage available across all DB instances.

* * @throws {@link StorageTypeNotSupportedFault} (client fault) *

The specified StorageType can't be associated with the DB instance.

* * @throws {@link RDSServiceException} *

Base exception class for all service exceptions from RDS service.

* * * @example To restore an Amazon Aurora DB cluster from Amazon S3 * ```javascript * // The following example restores an Amazon Aurora MySQL version 5.7-compatible DB cluster from a MySQL 5.7 DB backup file in Amazon S3. * const input = { * DBClusterIdentifier: "cluster-s3-restore", * Engine: "aurora-mysql", * MasterUserPassword: "mypassword", * MasterUsername: "admin", * S3BucketName: "mybucket", * S3IngestionRoleArn: "arn:aws:iam::123456789012:role/service-role/TestBackup", * S3Prefix: "test-backup", * SourceEngine: "mysql", * SourceEngineVersion: "5.7.28" * }; * const command = new RestoreDBClusterFromS3Command(input); * const response = await client.send(command); * /* response is * { * DBCluster: { * AllocatedStorage: 1, * AssociatedRoles: [], * AvailabilityZones: [ * "us-west-2c", * "us-west-2a", * "us-west-2b" * ], * BackupRetentionPeriod: 1, * ClusterCreateTime: "2020-07-27T14:22:08.095Z", * CopyTagsToSnapshot: false, * CrossAccountClone: false, * DBClusterArn: "arn:aws:rds:us-west-2:123456789012:cluster:cluster-s3-restore", * DBClusterIdentifier: "cluster-s3-restore", * DBClusterMembers: [], * DBClusterParameterGroup: "default.aurora-mysql5.7", * DBSubnetGroup: "default", * DbClusterResourceId: "cluster-SU5THYQQHOWCXZZDGXREXAMPLE", * DeletionProtection: false, * DomainMemberships: [], * Endpoint: "cluster-s3-restore.cluster-co3xyzabc123.us-west-2.rds.amazonaws.com", * Engine: "aurora-mysql", * EngineMode: "provisioned", * EngineVersion: "5.7.12", * HostedZoneId: "Z1PVIF0EXAMPLE", * HttpEndpointEnabled: false, * IAMDatabaseAuthenticationEnabled: false, * MasterUsername: "admin", * MultiAZ: false, * Port: 3306, * PreferredBackupWindow: "11:15-11:45", * PreferredMaintenanceWindow: "thu:12:19-thu:12:49", * ReadReplicaIdentifiers: [], * ReaderEndpoint: "cluster-s3-restore.cluster-ro-co3xyzabc123.us-west-2.rds.amazonaws.com", * Status: "creating", * StorageEncrypted: false, * VpcSecurityGroups: [ * { * Status: "active", * VpcSecurityGroupId: "sg-########" * } * ] * } * } * *\/ * ``` * * @public */ export declare class RestoreDBClusterFromS3Command extends RestoreDBClusterFromS3Command_base { /** @internal type navigation helper, not in runtime. */ protected static __types: { api: { input: RestoreDBClusterFromS3Message; output: RestoreDBClusterFromS3Result; }; sdk: { input: RestoreDBClusterFromS3CommandInput; output: RestoreDBClusterFromS3CommandOutput; }; }; }