/* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). * You may not use this file except in compliance with the License. * A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either * express or implied. See the License for the specific language governing * permissions and limitations under the License. */ /* * Do not modify this file. This file is generated from the rds-2014-10-31.normal.json service model. */ using System; using System.Collections.Generic; using System.Xml.Serialization; using System.Text; using System.IO; using System.Net; using Amazon.Runtime; using Amazon.Runtime.Internal; namespace Amazon.RDS.Model { /// /// Container for the parameters to the RestoreDBClusterFromS3 operation. /// 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 action only restores the DB cluster, not the DB instances for that DB cluster. /// You must invoke the CreateDBInstance action 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 action /// 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 action only applies to Aurora DB clusters. The source DB engine must be MySQL. /// /// /// public partial class RestoreDBClusterFromS3Request : AmazonRDSRequest { private List _availabilityZones = new List(); private long? _backtrackWindow; private int? _backupRetentionPeriod; private string _characterSetName; private bool? _copyTagsToSnapshot; private string _databaseName; private string _dbClusterIdentifier; private string _dbClusterParameterGroupName; private string _dbSubnetGroupName; private bool? _deletionProtection; private string _domain; private string _domainIAMRoleName; private List _enableCloudwatchLogsExports = new List(); private bool? _enableIAMDatabaseAuthentication; private string _engine; private string _engineVersion; private string _kmsKeyId; private bool? _manageMasterUserPassword; private string _masterUsername; private string _masterUserPassword; private string _masterUserSecretKmsKeyId; private string _networkType; private string _optionGroupName; private int? _port; private string _preferredBackupWindow; private string _preferredMaintenanceWindow; private string _s3BucketName; private string _s3IngestionRoleArn; private string _s3Prefix; private ServerlessV2ScalingConfiguration _serverlessV2ScalingConfiguration; private string _sourceEngine; private string _sourceEngineVersion; private bool? _storageEncrypted; private string _storageType; private List _tags = new List(); private List _vpcSecurityGroupIds = new List(); /// /// Gets and sets the property AvailabilityZones. /// /// A list of Availability Zones (AZs) where instances in the restored DB cluster can /// be created. /// /// public List AvailabilityZones { get { return this._availabilityZones; } set { this._availabilityZones = value; } } // Check to see if AvailabilityZones property is set internal bool IsSetAvailabilityZones() { return this._availabilityZones != null && this._availabilityZones.Count > 0; } /// /// Gets and sets the property BacktrackWindow. /// /// The target backtrack window, in seconds. To disable backtracking, set this value to /// 0. /// /// /// /// Currently, Backtrack is only supported for Aurora MySQL DB clusters. /// /// /// /// Default: 0 /// /// /// /// Constraints: /// ///
  • /// /// If specified, this value must be set to a number from 0 to 259,200 (72 hours). /// ///
///
public long BacktrackWindow { get { return this._backtrackWindow.GetValueOrDefault(); } set { this._backtrackWindow = value; } } // Check to see if BacktrackWindow property is set internal bool IsSetBacktrackWindow() { return this._backtrackWindow.HasValue; } /// /// Gets and sets the property BackupRetentionPeriod. /// /// The number of days for which automated backups of the restored DB cluster are retained. /// You must specify a minimum value of 1. /// /// /// /// Default: 1 /// /// /// /// Constraints: /// ///
  • /// /// Must be a value from 1 to 35 /// ///
///
public int BackupRetentionPeriod { get { return this._backupRetentionPeriod.GetValueOrDefault(); } set { this._backupRetentionPeriod = value; } } // Check to see if BackupRetentionPeriod property is set internal bool IsSetBackupRetentionPeriod() { return this._backupRetentionPeriod.HasValue; } /// /// Gets and sets the property CharacterSetName. /// /// A value that indicates that the restored DB cluster should be associated with the /// specified CharacterSet. /// /// public string CharacterSetName { get { return this._characterSetName; } set { this._characterSetName = value; } } // Check to see if CharacterSetName property is set internal bool IsSetCharacterSetName() { return this._characterSetName != null; } /// /// Gets and sets the property CopyTagsToSnapshot. /// /// A value that indicates whether to copy all tags from the restored DB cluster to snapshots /// of the restored DB cluster. The default is not to copy them. /// /// public bool CopyTagsToSnapshot { get { return this._copyTagsToSnapshot.GetValueOrDefault(); } set { this._copyTagsToSnapshot = value; } } // Check to see if CopyTagsToSnapshot property is set internal bool IsSetCopyTagsToSnapshot() { return this._copyTagsToSnapshot.HasValue; } /// /// Gets and sets the property DatabaseName. /// /// The database name for the restored DB cluster. /// /// public string DatabaseName { get { return this._databaseName; } set { this._databaseName = value; } } // Check to see if DatabaseName property is set internal bool IsSetDatabaseName() { return this._databaseName != null; } /// /// Gets and sets the property DBClusterIdentifier. /// /// The name of the DB cluster to create from the source data in the Amazon S3 bucket. /// This parameter isn't case-sensitive. /// /// /// /// Constraints: /// ///
  • /// /// Must contain from 1 to 63 letters, numbers, or hyphens. /// ///
  • /// /// First character must be a letter. /// ///
  • /// /// Can't end with a hyphen or contain two consecutive hyphens. /// ///
/// /// Example: my-cluster1 /// ///
[AWSProperty(Required=true)] public string DBClusterIdentifier { get { return this._dbClusterIdentifier; } set { this._dbClusterIdentifier = value; } } // Check to see if DBClusterIdentifier property is set internal bool IsSetDBClusterIdentifier() { return this._dbClusterIdentifier != null; } /// /// Gets and sets the property DBClusterParameterGroupName. /// /// The name of the DB cluster parameter group to associate with the restored DB cluster. /// If this argument is omitted, the default parameter group for the engine version is /// used. /// /// /// /// Constraints: /// ///
  • /// /// If supplied, must match the name of an existing DBClusterParameterGroup. /// ///
///
public string DBClusterParameterGroupName { get { return this._dbClusterParameterGroupName; } set { this._dbClusterParameterGroupName = value; } } // Check to see if DBClusterParameterGroupName property is set internal bool IsSetDBClusterParameterGroupName() { return this._dbClusterParameterGroupName != null; } /// /// Gets and sets the property DBSubnetGroupName. /// /// A DB subnet group to associate with the restored DB cluster. /// /// /// /// Constraints: If supplied, must match the name of an existing DBSubnetGroup. /// /// /// /// Example: mydbsubnetgroup /// /// public string DBSubnetGroupName { get { return this._dbSubnetGroupName; } set { this._dbSubnetGroupName = value; } } // Check to see if DBSubnetGroupName property is set internal bool IsSetDBSubnetGroupName() { return this._dbSubnetGroupName != null; } /// /// Gets and sets the property DeletionProtection. /// /// A value that indicates whether the DB cluster has deletion protection enabled. The /// database can't be deleted when deletion protection is enabled. By default, deletion /// protection isn't enabled. /// /// public bool DeletionProtection { get { return this._deletionProtection.GetValueOrDefault(); } set { this._deletionProtection = value; } } // Check to see if DeletionProtection property is set internal bool IsSetDeletionProtection() { return this._deletionProtection.HasValue; } /// /// Gets and sets the property Domain. /// /// Specify the Active Directory directory ID to restore the DB cluster in. The domain /// must be created prior to this operation. /// /// /// /// For Amazon Aurora DB clusters, Amazon RDS can use Kerberos Authentication to authenticate /// users that connect to the DB cluster. For more information, see Kerberos /// Authentication in the Amazon Aurora User Guide. /// /// public string Domain { get { return this._domain; } set { this._domain = value; } } // Check to see if Domain property is set internal bool IsSetDomain() { return this._domain != null; } /// /// Gets and sets the property DomainIAMRoleName. /// /// Specify the name of the IAM role to be used when making API calls to the Directory /// Service. /// /// public string DomainIAMRoleName { get { return this._domainIAMRoleName; } set { this._domainIAMRoleName = value; } } // Check to see if DomainIAMRoleName property is set internal bool IsSetDomainIAMRoleName() { return this._domainIAMRoleName != null; } /// /// Gets and sets the property EnableCloudwatchLogsExports. /// /// The list of logs that the restored DB cluster is to export to CloudWatch Logs. The /// values in the list depend on the DB engine being used. /// /// /// /// Aurora MySQL /// /// /// /// Possible values are audit, error, general, /// and slowquery. /// /// /// /// For more information about exporting CloudWatch Logs for Amazon Aurora, see Publishing /// Database Logs to Amazon CloudWatch Logs in the Amazon Aurora User Guide. /// /// public List EnableCloudwatchLogsExports { get { return this._enableCloudwatchLogsExports; } set { this._enableCloudwatchLogsExports = value; } } // Check to see if EnableCloudwatchLogsExports property is set internal bool IsSetEnableCloudwatchLogsExports() { return this._enableCloudwatchLogsExports != null && this._enableCloudwatchLogsExports.Count > 0; } /// /// Gets and sets the property EnableIAMDatabaseAuthentication. /// /// A value that indicates whether to enable mapping of Amazon Web Services Identity and /// Access Management (IAM) accounts to database accounts. By default, mapping isn't enabled. /// /// /// /// For more information, see /// IAM Database Authentication in the Amazon Aurora User Guide. /// /// public bool EnableIAMDatabaseAuthentication { get { return this._enableIAMDatabaseAuthentication.GetValueOrDefault(); } set { this._enableIAMDatabaseAuthentication = value; } } // Check to see if EnableIAMDatabaseAuthentication property is set internal bool IsSetEnableIAMDatabaseAuthentication() { return this._enableIAMDatabaseAuthentication.HasValue; } /// /// Gets and sets the property Engine. /// /// The name of the database engine to be used for this DB cluster. /// /// /// /// Valid Values: aurora-mysql (for Aurora MySQL) /// /// [AWSProperty(Required=true)] public string Engine { get { return this._engine; } set { this._engine = value; } } // Check to see if Engine property is set internal bool IsSetEngine() { return this._engine != null; } /// /// Gets and sets the property EngineVersion. /// /// The version number of the database engine to use. /// /// /// /// To list all of the available engine versions for aurora-mysql (Aurora /// MySQL), use the following command: /// /// /// /// aws rds describe-db-engine-versions --engine aurora-mysql --query "DBEngineVersions[].EngineVersion" /// /// /// /// /// Aurora MySQL /// /// /// /// Examples: 5.7.mysql_aurora.2.07.1, 8.0.mysql_aurora.3.02.0 /// /// /// public string EngineVersion { get { return this._engineVersion; } set { this._engineVersion = value; } } // Check to see if EngineVersion property is set internal bool IsSetEngineVersion() { return this._engineVersion != null; } /// /// Gets and sets the property KmsKeyId. /// /// The Amazon Web Services KMS key identifier for an encrypted DB cluster. /// /// /// /// The Amazon Web Services KMS key identifier is the key ARN, key ID, alias ARN, or alias /// name for the KMS key. To use a KMS key in a different Amazon Web Services account, /// specify the key ARN or alias ARN. /// /// /// /// If the StorageEncrypted parameter is enabled, and you do not specify a value for the /// KmsKeyId parameter, then Amazon RDS will use your default KMS key. There /// is a default KMS key for your Amazon Web Services account. Your Amazon Web Services /// account has a different default KMS key for each Amazon Web Services Region. /// /// public string KmsKeyId { get { return this._kmsKeyId; } set { this._kmsKeyId = value; } } // Check to see if KmsKeyId property is set internal bool IsSetKmsKeyId() { return this._kmsKeyId != null; } /// /// Gets and sets the property ManageMasterUserPassword. /// /// A value that indicates whether to manage the master user password with Amazon Web /// Services Secrets Manager. /// /// /// /// For more information, see Password /// management with Amazon Web Services Secrets Manager in the Amazon RDS User /// Guide and Password /// management with Amazon Web Services Secrets Manager in the Amazon Aurora User /// Guide. /// /// /// /// Constraints: /// ///
  • /// /// Can't manage the master user password with Amazon Web Services Secrets Manager if /// MasterUserPassword is specified. /// ///
///
public bool ManageMasterUserPassword { get { return this._manageMasterUserPassword.GetValueOrDefault(); } set { this._manageMasterUserPassword = value; } } // Check to see if ManageMasterUserPassword property is set internal bool IsSetManageMasterUserPassword() { return this._manageMasterUserPassword.HasValue; } /// /// Gets and sets the property MasterUsername. /// /// The name of the master user for the restored DB cluster. /// /// /// /// Constraints: /// ///
  • /// /// Must be 1 to 16 letters or numbers. /// ///
  • /// /// First character must be a letter. /// ///
  • /// /// Can't be a reserved word for the chosen database engine. /// ///
///
[AWSProperty(Required=true)] public string MasterUsername { get { return this._masterUsername; } set { this._masterUsername = value; } } // Check to see if MasterUsername property is set internal bool IsSetMasterUsername() { return this._masterUsername != null; } /// /// Gets and sets the property MasterUserPassword. /// /// The password for the master database user. This password can contain any printable /// ASCII character except "/", """, or "@". /// /// /// /// Constraints: /// ///
  • /// /// Must contain from 8 to 41 characters. /// ///
  • /// /// Can't be specified if ManageMasterUserPassword is turned on. /// ///
///
public string MasterUserPassword { get { return this._masterUserPassword; } set { this._masterUserPassword = value; } } // Check to see if MasterUserPassword property is set internal bool IsSetMasterUserPassword() { return this._masterUserPassword != null; } /// /// Gets and sets the property MasterUserSecretKmsKeyId. /// /// The Amazon Web Services KMS key identifier to encrypt a secret that is automatically /// generated and managed in Amazon Web Services Secrets Manager. /// /// /// /// This setting is valid only if the master user password is managed by RDS in Amazon /// Web Services Secrets Manager for the DB cluster. /// /// /// /// The Amazon Web Services KMS key identifier is the key ARN, key ID, alias ARN, or alias /// name for the KMS key. To use a KMS key in a different Amazon Web Services account, /// specify the key ARN or alias ARN. /// /// /// /// If you don't specify MasterUserSecretKmsKeyId, then the aws/secretsmanager /// KMS key is used to encrypt the secret. If the secret is in a different Amazon Web /// Services account, then you can't use the aws/secretsmanager KMS key to /// encrypt the secret, and you must use a customer managed KMS key. /// /// /// /// There is a default KMS key for your Amazon Web Services account. Your Amazon Web Services /// account has a different default KMS key for each Amazon Web Services Region. /// /// public string MasterUserSecretKmsKeyId { get { return this._masterUserSecretKmsKeyId; } set { this._masterUserSecretKmsKeyId = value; } } // Check to see if MasterUserSecretKmsKeyId property is set internal bool IsSetMasterUserSecretKmsKeyId() { return this._masterUserSecretKmsKeyId != null; } /// /// Gets and sets the property NetworkType. /// /// The network type of the DB cluster. /// /// /// /// Valid values: /// ///
  • /// /// IPV4 /// ///
  • /// /// DUAL /// ///
/// /// The network type is determined by the DBSubnetGroup specified for the /// DB cluster. A DBSubnetGroup can support only the IPv4 protocol or the /// IPv4 and the IPv6 protocols (DUAL). /// /// /// /// For more information, see /// Working with a DB instance in a VPC in the Amazon Aurora User Guide. /// ///
public string NetworkType { get { return this._networkType; } set { this._networkType = value; } } // Check to see if NetworkType property is set internal bool IsSetNetworkType() { return this._networkType != null; } /// /// Gets and sets the property OptionGroupName. /// /// A value that indicates that the restored DB cluster should be associated with the /// specified option group. /// /// /// /// Permanent options can't be removed from an option group. An option group can't be /// removed from a DB cluster once it is associated with a DB cluster. /// /// public string OptionGroupName { get { return this._optionGroupName; } set { this._optionGroupName = value; } } // Check to see if OptionGroupName property is set internal bool IsSetOptionGroupName() { return this._optionGroupName != null; } /// /// Gets and sets the property Port. /// /// The port number on which the instances in the restored DB cluster accept connections. /// /// /// /// Default: 3306 /// /// public int Port { get { return this._port.GetValueOrDefault(); } set { this._port = value; } } // Check to see if Port property is set internal bool IsSetPort() { return this._port.HasValue; } /// /// Gets and sets the property PreferredBackupWindow. /// /// The daily time range during which automated backups are created if automated backups /// are enabled using the BackupRetentionPeriod parameter. /// /// /// /// The default is a 30-minute window selected at random from an 8-hour block of time /// for each Amazon Web Services Region. To view the time blocks available, see /// Backup window in the Amazon Aurora User Guide. /// /// /// /// Constraints: /// ///
  • /// /// Must be in the format hh24:mi-hh24:mi. /// ///
  • /// /// Must be in Universal Coordinated Time (UTC). /// ///
  • /// /// Must not conflict with the preferred maintenance window. /// ///
  • /// /// Must be at least 30 minutes. /// ///
///
public string PreferredBackupWindow { get { return this._preferredBackupWindow; } set { this._preferredBackupWindow = value; } } // Check to see if PreferredBackupWindow property is set internal bool IsSetPreferredBackupWindow() { return this._preferredBackupWindow != null; } /// /// Gets and sets the property PreferredMaintenanceWindow. /// /// The weekly time range during which system maintenance can occur, in Universal Coordinated /// Time (UTC). /// /// /// /// Format: ddd:hh24:mi-ddd:hh24:mi /// /// /// /// The default is a 30-minute window selected at random from an 8-hour block of time /// for each Amazon Web Services Region, occurring on a random day of the week. To see /// the time blocks available, see /// Adjusting the Preferred Maintenance Window in the Amazon Aurora User Guide. /// /// /// /// Valid Days: Mon, Tue, Wed, Thu, Fri, Sat, Sun. /// /// /// /// Constraints: Minimum 30-minute window. /// /// public string PreferredMaintenanceWindow { get { return this._preferredMaintenanceWindow; } set { this._preferredMaintenanceWindow = value; } } // Check to see if PreferredMaintenanceWindow property is set internal bool IsSetPreferredMaintenanceWindow() { return this._preferredMaintenanceWindow != null; } /// /// Gets and sets the property S3BucketName. /// /// The name of the Amazon S3 bucket that contains the data used to create the Amazon /// Aurora DB cluster. /// /// [AWSProperty(Required=true)] public string S3BucketName { get { return this._s3BucketName; } set { this._s3BucketName = value; } } // Check to see if S3BucketName property is set internal bool IsSetS3BucketName() { return this._s3BucketName != null; } /// /// Gets and sets the property S3IngestionRoleArn. /// /// The Amazon Resource Name (ARN) of the Amazon Web Services Identity and Access Management /// (IAM) role that authorizes Amazon RDS to access the Amazon S3 bucket on your behalf. /// /// [AWSProperty(Required=true)] public string S3IngestionRoleArn { get { return this._s3IngestionRoleArn; } set { this._s3IngestionRoleArn = value; } } // Check to see if S3IngestionRoleArn property is set internal bool IsSetS3IngestionRoleArn() { return this._s3IngestionRoleArn != null; } /// /// Gets and sets the property S3Prefix. /// /// The prefix for all of the file names that contain the data used to create the Amazon /// Aurora DB cluster. If you do not specify a SourceS3Prefix value, then the Amazon /// Aurora DB cluster is created by using all of the files in the Amazon S3 bucket. /// /// public string S3Prefix { get { return this._s3Prefix; } set { this._s3Prefix = value; } } // Check to see if S3Prefix property is set internal bool IsSetS3Prefix() { return this._s3Prefix != null; } /// /// Gets and sets the property ServerlessV2ScalingConfiguration. /// public ServerlessV2ScalingConfiguration ServerlessV2ScalingConfiguration { get { return this._serverlessV2ScalingConfiguration; } set { this._serverlessV2ScalingConfiguration = value; } } // Check to see if ServerlessV2ScalingConfiguration property is set internal bool IsSetServerlessV2ScalingConfiguration() { return this._serverlessV2ScalingConfiguration != null; } /// /// Gets and sets the property SourceEngine. /// /// The identifier for the database engine that was backed up to create the files stored /// in the Amazon S3 bucket. /// /// /// /// Valid values: mysql /// /// [AWSProperty(Required=true)] public string SourceEngine { get { return this._sourceEngine; } set { this._sourceEngine = value; } } // Check to see if SourceEngine property is set internal bool IsSetSourceEngine() { return this._sourceEngine != null; } /// /// Gets and sets the property SourceEngineVersion. /// /// The version of the database that the backup files were created from. /// /// /// /// MySQL versions 5.5, 5.6, and 5.7 are supported. /// /// /// /// Example: 5.6.40, 5.7.28 /// /// [AWSProperty(Required=true)] public string SourceEngineVersion { get { return this._sourceEngineVersion; } set { this._sourceEngineVersion = value; } } // Check to see if SourceEngineVersion property is set internal bool IsSetSourceEngineVersion() { return this._sourceEngineVersion != null; } /// /// Gets and sets the property StorageEncrypted. /// /// A value that indicates whether the restored DB cluster is encrypted. /// /// public bool StorageEncrypted { get { return this._storageEncrypted.GetValueOrDefault(); } set { this._storageEncrypted = value; } } // Check to see if StorageEncrypted property is set internal bool IsSetStorageEncrypted() { return this._storageEncrypted.HasValue; } /// /// Gets and sets the property StorageType. /// /// Specifies the storage type to be associated with the DB cluster. /// /// /// /// Valid values: aurora, aurora-iopt1 /// /// /// /// Default: aurora /// /// /// /// Valid for: Aurora DB clusters only /// /// public string StorageType { get { return this._storageType; } set { this._storageType = value; } } // Check to see if StorageType property is set internal bool IsSetStorageType() { return this._storageType != null; } /// /// Gets and sets the property Tags. /// public List Tags { get { return this._tags; } set { this._tags = value; } } // Check to see if Tags property is set internal bool IsSetTags() { return this._tags != null && this._tags.Count > 0; } /// /// Gets and sets the property VpcSecurityGroupIds. /// /// A list of EC2 VPC security groups to associate with the restored DB cluster. /// /// public List VpcSecurityGroupIds { get { return this._vpcSecurityGroupIds; } set { this._vpcSecurityGroupIds = value; } } // Check to see if VpcSecurityGroupIds property is set internal bool IsSetVpcSecurityGroupIds() { return this._vpcSecurityGroupIds != null && this._vpcSecurityGroupIds.Count > 0; } } }