Class: Aws::RDS::Resource

Inherits:
Object
  • Object
show all
Defined in:
lib/aws-sdk-rds/resource.rb

Overview

This class provides a resource oriented interface for RDS. To create a resource object:

resource = Aws::RDS::Resource.new(region: 'us-west-2')

You can supply a client object with custom configuration that will be used for all resource operations. If you do not pass ‘:client`, a default client will be constructed.

client = Aws::RDS::Client.new(region: 'us-west-2')
resource = Aws::RDS::Resource.new(client: client)

Actions collapse

Associations collapse

Instance Method Summary collapse

Constructor Details

#initialize(options = {}) ⇒ Resource

Returns a new instance of Resource.

Parameters:

  • options ({}) (defaults to: {})

Options Hash (options):



27
28
29
# File 'lib/aws-sdk-rds/resource.rb', line 27

def initialize(options = {})
  @client = options[:client] || Client.new(options)
end

Instance Method Details

#account_quotas(options = {}) ⇒ AccountQuota::Collection

Examples:

Request syntax with placeholder values


rds.()

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Returns:



2783
2784
2785
2786
2787
2788
2789
2790
2791
2792
2793
2794
2795
2796
2797
2798
2799
# File 'lib/aws-sdk-rds/resource.rb', line 2783

def (options = {})
  batches = Enumerator.new do |y|
    batch = []
    resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
      @client.(options)
    end
    resp.data..each do |a|
      batch << AccountQuota.new(
        name: a.,
        data: a,
        client: @client
      )
    end
    y.yield(batch)
  end
  AccountQuota::Collection.new(batches)
end

#certificate(id) ⇒ Certificate

Parameters:

  • id (String)

Returns:



2803
2804
2805
2806
2807
2808
# File 'lib/aws-sdk-rds/resource.rb', line 2803

def certificate(id)
  Certificate.new(
    id: id,
    client: @client
  )
end

#certificates(options = {}) ⇒ Certificate::Collection

Examples:

Request syntax with placeholder values


certificates = rds.certificates({
  certificate_identifier: "String",
  filters: [
    {
      name: "String", # required
      values: ["String"], # required
    },
  ],
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :certificate_identifier (String)

    The user-supplied certificate identifier. If this parameter is specified, information for only the identified certificate is returned. This parameter isn’t case-sensitive.

    Constraints:

    • Must match an existing CertificateIdentifier.

    ^

  • :filters (Array<Types::Filter>)

    This parameter isn’t currently supported.

Returns:



2835
2836
2837
2838
2839
2840
2841
2842
2843
2844
2845
2846
2847
2848
2849
2850
2851
2852
2853
# File 'lib/aws-sdk-rds/resource.rb', line 2835

def certificates(options = {})
  batches = Enumerator.new do |y|
    resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
      @client.describe_certificates(options)
    end
    resp.each_page do |page|
      batch = []
      page.data.certificates.each do |c|
        batch << Certificate.new(
          id: c.certificate_identifier,
          data: c,
          client: @client
        )
      end
      y.yield(batch)
    end
  end
  Certificate::Collection.new(batches)
end

#clientClient

Returns:



32
33
34
# File 'lib/aws-sdk-rds/resource.rb', line 32

def client
  @client
end

#create_db_cluster(options = {}) ⇒ DBCluster

Examples:

Request syntax with placeholder values


dbcluster = rds.create_db_cluster({
  availability_zones: ["String"],
  backup_retention_period: 1,
  character_set_name: "String",
  database_name: "String",
  db_cluster_identifier: "String", # required
  db_cluster_parameter_group_name: "String",
  vpc_security_group_ids: ["String"],
  db_subnet_group_name: "String",
  engine: "String", # required
  engine_version: "String",
  port: 1,
  master_username: "String",
  master_user_password: "String",
  option_group_name: "String",
  preferred_backup_window: "String",
  preferred_maintenance_window: "String",
  replication_source_identifier: "String",
  tags: [
    {
      key: "String",
      value: "String",
    },
  ],
  storage_encrypted: false,
  kms_key_id: "String",
  pre_signed_url: "String",
  enable_iam_database_authentication: false,
  backtrack_window: 1,
  enable_cloudwatch_logs_exports: ["String"],
  engine_mode: "String",
  scaling_configuration: {
    min_capacity: 1,
    max_capacity: 1,
    auto_pause: false,
    seconds_until_auto_pause: 1,
    timeout_action: "String",
    seconds_before_timeout: 1,
  },
  rds_custom_cluster_configuration: {
    interconnect_subnet_id: "String",
    transit_gateway_multicast_domain_id: "String",
    replica_mode: "open-read-only", # accepts open-read-only, mounted
  },
  deletion_protection: false,
  global_cluster_identifier: "String",
  enable_http_endpoint: false,
  copy_tags_to_snapshot: false,
  domain: "String",
  domain_iam_role_name: "String",
  enable_global_write_forwarding: false,
  db_cluster_instance_class: "String",
  allocated_storage: 1,
  storage_type: "String",
  iops: 1,
  publicly_accessible: false,
  auto_minor_version_upgrade: false,
  monitoring_interval: 1,
  monitoring_role_arn: "String",
  enable_performance_insights: false,
  performance_insights_kms_key_id: "String",
  performance_insights_retention_period: 1,
  enable_limitless_database: false,
  serverless_v2_scaling_configuration: {
    min_capacity: 1.0,
    max_capacity: 1.0,
    seconds_until_auto_pause: 1,
  },
  network_type: "String",
  cluster_scalability_type: "standard", # accepts standard, limitless
  db_system_id: "String",
  manage_master_user_password: false,
  master_user_secret_kms_key_id: "String",
  enable_local_write_forwarding: false,
  ca_certificate_identifier: "String",
  engine_lifecycle_support: "String",
  source_region: "String",
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :availability_zones (Array<String>)

    A list of Availability Zones (AZs) where you specifically want to create DB instances in the DB cluster.

    For information on AZs, see [Availability Zones] in the *Amazon Aurora User Guide*.

    Valid for Cluster Type: Aurora DB clusters only

    Constraints:

    • Can’t specify more than three AZs.

    ^

    [1]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/Concepts.RegionsAndAvailabilityZones.html#Concepts.RegionsAndAvailabilityZones.AvailabilityZones

  • :backup_retention_period (Integer)

    The number of days for which automated backups are retained.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

    Default: ‘1`

    Constraints:

    • Must be a value from 1 to 35.

    ^

  • :character_set_name (String)

    The name of the character set (‘CharacterSet`) to associate the DB cluster with.

    Valid for Cluster Type: Aurora DB clusters only

  • :database_name (String)

    The name for your database of up to 64 alphanumeric characters. A database named ‘postgres` is always created. If this parameter is specified, an additional database with this name is created.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

  • :db_cluster_identifier (required, String)

    The identifier for this DB cluster. This parameter is stored as a lowercase string.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

    Constraints:

    • Must contain from 1 to 63 (for Aurora DB clusters) or 1 to 52 (for Multi-AZ DB clusters) letters, numbers, or hyphens.

    • First character must be a letter.

    • Can’t end with a hyphen or contain two consecutive hyphens.

    Example: ‘my-cluster1`

  • :db_cluster_parameter_group_name (String)

    The name of the DB cluster parameter group to associate with this DB cluster. If you don’t specify a value, then the default DB cluster parameter group for the specified DB engine and version is used.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

    Constraints:

    • If supplied, must match the name of an existing DB cluster parameter group.

    ^

  • :vpc_security_group_ids (Array<String>)

    A list of EC2 VPC security groups to associate with this DB cluster.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

  • :db_subnet_group_name (String)

    A DB subnet group to associate with this DB cluster.

    This setting is required to create a Multi-AZ DB cluster.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

    Constraints:

    • Must match the name of an existing DB subnet group.

    ^

    Example: ‘mydbsubnetgroup`

  • :engine (required, String)

    The database engine to use for this DB cluster.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

    Valid Values:

    • ‘aurora-mysql`

    • ‘aurora-postgresql`

    • ‘mysql`

    • ‘postgres`

    • ‘neptune` - For information about using Amazon Neptune, see the [ *Amazon Neptune User Guide* ][1].

    [1]: docs.aws.amazon.com/neptune/latest/userguide/intro.html

  • :engine_version (String)

    The version number of the database engine to use.

    To list all of the available engine versions for Aurora MySQL version 2 (5.7-compatible) and version 3 (MySQL 8.0-compatible), use the following command:

    ‘aws rds describe-db-engine-versions –engine aurora-mysql –query “DBEngineVersions[].EngineVersion”`

    You can supply either ‘5.7` or `8.0` to use the default engine version for Aurora MySQL version 2 or version 3, respectively.

    To list all of the available engine versions for Aurora PostgreSQL, use the following command:

    ‘aws rds describe-db-engine-versions –engine aurora-postgresql –query “DBEngineVersions[].EngineVersion”`

    To list all of the available engine versions for RDS for MySQL, use the following command:

    ‘aws rds describe-db-engine-versions –engine mysql –query “DBEngineVersions[].EngineVersion”`

    To list all of the available engine versions for RDS for PostgreSQL, use the following command:

    ‘aws rds describe-db-engine-versions –engine postgres –query “DBEngineVersions[].EngineVersion”`

    For information about a specific engine, see the following topics:

    • Aurora MySQL - see [Database engine updates for Amazon Aurora MySQL] in the *Amazon Aurora User Guide*.

    • Aurora PostgreSQL - see [Amazon Aurora PostgreSQL releases and engine versions] in the *Amazon Aurora User Guide*.

    • RDS for MySQL - see [Amazon RDS for MySQL] in the *Amazon RDS User Guide*.

    • RDS for PostgreSQL - see [Amazon RDS for PostgreSQL] in the *Amazon RDS User Guide*.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

    [1]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/AuroraMySQL.Updates.html [2]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/AuroraPostgreSQL.Updates.20180305.html [3]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_MySQL.html#MySQL.Concepts.VersionMgmt [4]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_PostgreSQL.html#PostgreSQL.Concepts

  • :port (Integer)

    The port number on which the instances in the DB cluster accept connections.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

    Valid Values: ‘1150-65535`

    Default:

    • RDS for MySQL and Aurora MySQL - ‘3306`

    • RDS for PostgreSQL and Aurora PostgreSQL - ‘5432`

  • :master_username (String)

    The name of the master user for the DB cluster.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

    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.

  • :master_user_password (String)

    The password for the master database user.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

    Constraints:

    • Must contain from 8 to 41 characters.

    • Can contain any printable ASCII character except “/”, “”“, or ”@“.

    • Can’t be specified if ‘ManageMasterUserPassword` is turned on.

  • :option_group_name (String)

    The option group to associate the DB cluster with.

    DB clusters are associated with a default option group that can’t be modified.

  • :preferred_backup_window (String)

    The daily time range during which automated backups are created if automated backups are enabled using the ‘BackupRetentionPeriod` parameter.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

    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.

    [1]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/Aurora.Managing.Backups.html#Aurora.Managing.Backups.BackupWindow

  • :preferred_maintenance_window (String)

    The weekly time range during which system maintenance can occur.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

    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 DB Cluster Maintenance Window] in the *Amazon Aurora User Guide*.

    Constraints:

    • Must be in the format ‘ddd:hh24:mi-ddd:hh24:mi`.

    • Days must be one of ‘Mon | Tue | Wed | Thu | Fri | Sat | Sun`.

    • Must be in Universal Coordinated Time (UTC).

    • Must be at least 30 minutes.

    [1]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/USER_UpgradeDBInstance.Maintenance.html#AdjustingTheMaintenanceWindow.Aurora

  • :replication_source_identifier (String)

    The Amazon Resource Name (ARN) of the source DB instance or DB cluster if this DB cluster is created as a read replica.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

  • :tags (Array<Types::Tag>)

    Tags to assign to the DB cluster.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

  • :storage_encrypted (Boolean)

    Specifies whether the DB cluster is encrypted.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

  • :kms_key_id (String)

    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.

    When a KMS key isn’t specified in ‘KmsKeyId`:

    • If ‘ReplicationSourceIdentifier` identifies an encrypted source, then Amazon RDS uses the KMS key used to encrypt the source. Otherwise, Amazon RDS uses your default KMS key.

    • If the ‘StorageEncrypted` parameter is enabled and `ReplicationSourceIdentifier` isn’t specified, then Amazon RDS uses 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.

    If you create a read replica of an encrypted DB cluster in another Amazon Web Services Region, make sure to set ‘KmsKeyId` to a KMS key identifier that is valid in the destination Amazon Web Services Region. This KMS key is used to encrypt the read replica in that Amazon Web Services Region.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

  • :pre_signed_url (String)

    When you are replicating a DB cluster from one Amazon Web Services GovCloud (US) Region to another, an URL that contains a Signature Version 4 signed request for the ‘CreateDBCluster` operation to be called in the source Amazon Web Services Region where the DB cluster is replicated from. Specify `PreSignedUrl` only when you are performing cross-Region replication from an encrypted DB cluster.

    The presigned URL must be a valid request for the ‘CreateDBCluster` API operation that can run in the source Amazon Web Services Region that contains the encrypted DB cluster to copy.

    The presigned URL request must contain the following parameter values:

    • ‘KmsKeyId` - The KMS key identifier for the KMS key to use to encrypt the copy of the DB cluster in the destination Amazon Web Services Region. This should refer to the same KMS key for both the `CreateDBCluster` operation that is called in the destination Amazon Web Services Region, and the operation contained in the presigned URL.

    • ‘DestinationRegion` - The name of the Amazon Web Services Region that Aurora read replica will be created in.

    • ‘ReplicationSourceIdentifier` - The DB cluster identifier for the encrypted DB cluster to be copied. This identifier must be in the Amazon Resource Name (ARN) format for the source Amazon Web Services Region. For example, if you are copying an encrypted DB cluster from the us-west-2 Amazon Web Services Region, then your `ReplicationSourceIdentifier` would look like Example: `arn:aws:rds:us-west-2:123456789012:cluster:aurora-cluster1`.

    To learn how to generate a Signature Version 4 signed request, see [ Authenticating Requests: Using Query Parameters (Amazon Web Services Signature Version 4)] and [ Signature Version 4 Signing Process].

    <note markdown=“1”> If you are using an Amazon Web Services SDK tool or the CLI, you can specify ‘SourceRegion` (or `–source-region` for the CLI) instead of specifying `PreSignedUrl` manually. Specifying `SourceRegion` autogenerates a presigned URL that is a valid request for the operation that can run in the source Amazon Web Services Region.

    </note>
    

    Valid for Cluster Type: Aurora DB clusters only

    [1]: docs.aws.amazon.com/AmazonS3/latest/API/sigv4-query-string-auth.html [2]: docs.aws.amazon.com/general/latest/gr/signature-version-4.html

  • :enable_iam_database_authentication (Boolean)

    Specifies 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* or [IAM database authentication for MariaDB, MySQL, and PostgreSQL] in the *Amazon RDS User Guide*.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

    [1]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/UsingWithRDS.IAMDBAuth.html [2]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/UsingWithRDS.IAMDBAuth.html

  • :backtrack_window (Integer)

    The target backtrack window, in seconds. To disable backtracking, set this value to ‘0`.

    Valid for Cluster Type: Aurora MySQL DB clusters only

    Default: ‘0`

    Constraints:

    • If specified, this value must be set to a number from 0 to 259,200 (72 hours).

    ^

  • :enable_cloudwatch_logs_exports (Array<String>)

    The list of log types that need to be enabled for exporting to CloudWatch Logs.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

    The following values are valid for each DB engine:

    • Aurora MySQL - ‘audit | error | general | slowquery`

    • Aurora PostgreSQL - ‘postgresql`

    • RDS for MySQL - ‘error | general | slowquery`

    • RDS for PostgreSQL - ‘postgresql | upgrade`

    For more information about exporting CloudWatch Logs for Amazon RDS, see [Publishing Database Logs to Amazon CloudWatch Logs] in the *Amazon RDS User Guide*.

    For more information about exporting CloudWatch Logs for Amazon Aurora, see [Publishing Database Logs to Amazon CloudWatch Logs] in the *Amazon Aurora User Guide*.

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_LogAccess.html#USER_LogAccess.Procedural.UploadtoCloudWatch [2]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/USER_LogAccess.html#USER_LogAccess.Procedural.UploadtoCloudWatch

  • :engine_mode (String)

    The DB engine mode of the DB cluster, either ‘provisioned` or `serverless`.

    The ‘serverless` engine mode only applies for Aurora Serverless v1 DB clusters. Aurora Serverless v2 DB clusters use the `provisioned` engine mode.

    For information about limitations and requirements for Serverless DB clusters, see the following sections in the *Amazon Aurora User Guide*:

    • Limitations of Aurora Serverless v1][1
    • Requirements for Aurora Serverless v2][2

    Valid for Cluster Type: Aurora DB clusters only

    [1]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/aurora-serverless.html#aurora-serverless.limitations [2]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/aurora-serverless-v2.requirements.html

  • :scaling_configuration (Types::ScalingConfiguration)

    For DB clusters in ‘serverless` DB engine mode, the scaling properties of the DB cluster.

    Valid for Cluster Type: Aurora DB clusters only

  • :rds_custom_cluster_configuration (Types::RdsCustomClusterConfiguration)

    Reserved for future use.

  • :deletion_protection (Boolean)

    Specifies 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.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

  • :global_cluster_identifier (String)

    The global cluster ID of an Aurora cluster that becomes the primary cluster in the new global database cluster.

    Valid for Cluster Type: Aurora DB clusters only

  • :enable_http_endpoint (Boolean)

    Specifies whether to enable the HTTP endpoint for the DB cluster. By default, the HTTP endpoint isn’t enabled.

    When enabled, the HTTP endpoint provides a connectionless web service API (RDS Data API) for running SQL queries on the DB cluster. You can also query your database from inside the RDS console with the RDS query editor.

    RDS Data API is supported with the following DB clusters:

    • Aurora PostgreSQL Serverless v2 and provisioned

    • Aurora PostgreSQL and Aurora MySQL Serverless v1

    For more information, see [Using RDS Data API] in the *Amazon Aurora User Guide*.

    Valid for Cluster Type: Aurora DB clusters only

    [1]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/data-api.html

  • :copy_tags_to_snapshot (Boolean)

    Specifies whether to copy all tags from the DB cluster to snapshots of the DB cluster. The default is not to copy them.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

  • :domain (String)

    The Active Directory directory ID to create the DB cluster in.

    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*.

    Valid for Cluster Type: Aurora DB clusters only

    [1]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/kerberos-authentication.html

  • :domain_iam_role_name (String)

    The name of the IAM role to use when making API calls to the Directory Service.

    Valid for Cluster Type: Aurora DB clusters only

  • :enable_global_write_forwarding (Boolean)

    Specifies whether to enable this DB cluster to forward write operations to the primary cluster of a global cluster (Aurora global database). By default, write operations are not allowed on Aurora DB clusters that are secondary clusters in an Aurora global database.

    You can set this value only on Aurora DB clusters that are members of an Aurora global database. With this parameter enabled, a secondary cluster can forward writes to the current primary cluster, and the resulting changes are replicated back to this cluster. For the primary DB cluster of an Aurora global database, this value is used immediately if the primary is demoted by a global cluster API operation, but it does nothing until then.

    Valid for Cluster Type: Aurora DB clusters only

  • :db_cluster_instance_class (String)

    The compute and memory capacity of each DB instance in the Multi-AZ DB cluster, for example ‘db.m6gd.xlarge`. Not all DB instance classes are available in all Amazon Web Services Regions, or for all database engines.

    For the full list of DB instance classes and availability for your engine, see [DB instance class] in the *Amazon RDS User Guide*.

    This setting is required to create a Multi-AZ DB cluster.

    Valid for Cluster Type: Multi-AZ DB clusters only

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Concepts.DBInstanceClass.html

  • :allocated_storage (Integer)

    The amount of storage in gibibytes (GiB) to allocate to each DB instance in the Multi-AZ DB cluster.

    Valid for Cluster Type: Multi-AZ DB clusters only

    This setting is required to create a Multi-AZ DB cluster.

  • :storage_type (String)

    The storage type to associate with the DB cluster.

    For information on storage types for Aurora DB clusters, see [Storage configurations for Amazon Aurora DB clusters]. For information on storage types for Multi-AZ DB clusters, see [Settings for creating Multi-AZ DB clusters].

    This setting is required to create a Multi-AZ DB cluster.

    When specified for a Multi-AZ DB cluster, a value for the ‘Iops` parameter is required.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

    Valid Values:

    • Aurora DB clusters - ‘aurora | aurora-iopt1`

    • Multi-AZ DB clusters - ‘io1 | io2 | gp3`

    Default:

    • Aurora DB clusters - ‘aurora`

    • Multi-AZ DB clusters - ‘io1`

    <note markdown=“1”> When you create an Aurora DB cluster with the storage type set to ‘aurora-iopt1`, the storage type is returned in the response. The storage type isn’t returned when you set it to ‘aurora`.

    </note>
    

    [1]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/Aurora.Overview.StorageReliability.html#aurora-storage-type [2]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/create-multi-az-db-cluster.html#create-multi-az-db-cluster-settings

  • :iops (Integer)

    The amount of Provisioned IOPS (input/output operations per second) to be initially allocated for each DB instance in the Multi-AZ DB cluster.

    For information about valid IOPS values, see [Provisioned IOPS storage] in the *Amazon RDS User Guide*.

    This setting is required to create a Multi-AZ DB cluster.

    Valid for Cluster Type: Multi-AZ DB clusters only

    Constraints:

    • Must be a multiple between .5 and 50 of the storage amount for the DB cluster.

    ^

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_Storage.html#USER_PIOPS

  • :publicly_accessible (Boolean)

    Specifies whether the DB cluster is publicly accessible.

    When the DB cluster is publicly accessible and you connect from outside of the DB cluster’s virtual private cloud (VPC), its Domain Name System (DNS) endpoint resolves to the public IP address. When you connect from within the same VPC as the DB cluster, the endpoint resolves to the private IP address. Access to the DB cluster is ultimately controlled by the security group it uses. That public access isn’t permitted if the security group assigned to the DB cluster doesn’t permit it.

    When the DB cluster isn’t publicly accessible, it is an internal DB cluster with a DNS name that resolves to a private IP address.

    Valid for Cluster Type: Multi-AZ DB clusters only

    Default: The default behavior varies depending on whether ‘DBSubnetGroupName` is specified.

    If ‘DBSubnetGroupName` isn’t specified, and ‘PubliclyAccessible` isn’t specified, the following applies:

    • If the default VPC in the target Region doesn’t have an internet gateway attached to it, the DB cluster is private.

    • If the default VPC in the target Region has an internet gateway attached to it, the DB cluster is public.

    If ‘DBSubnetGroupName` is specified, and `PubliclyAccessible` isn’t specified, the following applies:

    • If the subnets are part of a VPC that doesn’t have an internet gateway attached to it, the DB cluster is private.

    • If the subnets are part of a VPC that has an internet gateway attached to it, the DB cluster is public.

  • :auto_minor_version_upgrade (Boolean)

    Specifies whether minor engine upgrades are applied automatically to the DB cluster during the maintenance window. By default, minor engine upgrades are applied automatically.

    Valid for Cluster Type: Multi-AZ DB clusters only

  • :monitoring_interval (Integer)

    The interval, in seconds, between points when Enhanced Monitoring metrics are collected for the DB cluster. To turn off collecting Enhanced Monitoring metrics, specify ‘0`.

    If ‘MonitoringRoleArn` is specified, also set `MonitoringInterval` to a value other than `0`.

    Valid for Cluster Type: Multi-AZ DB clusters only

    Valid Values: ‘0 | 1 | 5 | 10 | 15 | 30 | 60`

    Default: ‘0`

  • :monitoring_role_arn (String)

    The Amazon Resource Name (ARN) for the IAM role that permits RDS to send Enhanced Monitoring metrics to Amazon CloudWatch Logs. An example is ‘arn:aws:iam:123456789012:role/emaccess`. For information on creating a monitoring role, see [Setting up and enabling Enhanced Monitoring] in the *Amazon RDS User Guide*.

    If ‘MonitoringInterval` is set to a value other than `0`, supply a `MonitoringRoleArn` value.

    Valid for Cluster Type: Multi-AZ DB clusters only

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Monitoring.OS.html#USER_Monitoring.OS.Enabling

  • :enable_performance_insights (Boolean)

    Specifies whether to turn on Performance Insights for the DB cluster.

    For more information, see [ Using Amazon Performance Insights] in the *Amazon RDS User Guide*.

    Valid for Cluster Type: Multi-AZ DB clusters only

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_PerfInsights.html

  • :performance_insights_kms_key_id (String)

    The Amazon Web Services KMS key identifier for encryption of Performance Insights data.

    The Amazon Web Services KMS key identifier is the key ARN, key ID, alias ARN, or alias name for the KMS key.

    If you don’t specify a value for ‘PerformanceInsightsKMSKeyId`, then Amazon RDS uses 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.

    Valid for Cluster Type: Multi-AZ DB clusters only

  • :performance_insights_retention_period (Integer)

    The number of days to retain Performance Insights data.

    Valid for Cluster Type: Multi-AZ DB clusters only

    Valid Values:

    • ‘7`

    • month * 31, where month is a number of months from 1-23. Examples: ‘93` (3 months * 31), `341` (11 months * 31), `589` (19 months * 31)

    • ‘731`

    Default: ‘7` days

    If you specify a retention period that isn’t valid, such as ‘94`, Amazon RDS issues an error.

  • :enable_limitless_database (Boolean)

    Specifies whether to enable Aurora Limitless Database. You must enable Aurora Limitless Database to create a DB shard group.

    Valid for: Aurora DB clusters only

    <note markdown=“1”> This setting is no longer used. Instead use the ‘ClusterScalabilityType` setting.

    </note>
    
  • :serverless_v2_scaling_configuration (Types::ServerlessV2ScalingConfiguration)

    Contains the scaling configuration of an Aurora Serverless v2 DB cluster.

    For more information, see [Using Amazon Aurora Serverless v2] in the *Amazon Aurora User Guide*.

    [1]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/aurora-serverless-v2.html

  • :network_type (String)

    The network type of the DB cluster.

    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.*

    Valid for Cluster Type: Aurora DB clusters only

    Valid Values: ‘IPV4 | DUAL`

    [1]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/USER_VPC.WorkingWithRDSInstanceinaVPC.html

  • :cluster_scalability_type (String)

    Specifies the scalability mode of the Aurora DB cluster. When set to ‘limitless`, the cluster operates as an Aurora Limitless Database. When set to `standard` (the default), the cluster uses normal DB instance creation.

    Valid for: Aurora DB clusters only

    <note markdown=“1”> You can’t modify this setting after you create the DB cluster.

    </note>
    
  • :db_system_id (String)

    Reserved for future use.

  • :manage_master_user_password (Boolean)

    Specifies 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][2

    in

    the *Amazon Aurora User Guide.*

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

    Constraints:

    • Can’t manage the master user password with Amazon Web Services Secrets Manager if ‘MasterUserPassword` is specified.

    ^

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/rds-secrets-manager.html [2]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/rds-secrets-manager.html

  • :master_user_secret_kms_key_id (String)

    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.

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

  • :enable_local_write_forwarding (Boolean)

    Specifies whether read replicas can forward write operations to the writer DB instance in the DB cluster. By default, write operations aren’t allowed on reader DB instances.

    Valid for: Aurora DB clusters only

  • :ca_certificate_identifier (String)

    The CA certificate identifier to use for the DB cluster’s server certificate.

    For more information, see [Using SSL/TLS to encrypt a connection to a DB instance] in the *Amazon RDS User Guide*.

    Valid for Cluster Type: Multi-AZ DB clusters

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/UsingWithRDS.SSL.html

  • :engine_lifecycle_support (String)

    The life cycle type for this DB cluster.

    <note markdown=“1”> By default, this value is set to ‘open-source-rds-extended-support`, which enrolls your DB cluster into Amazon RDS Extended Support. At the end of standard support, you can avoid charges for Extended Support by setting the value to `open-source-rds-extended-support-disabled`. In this case, creating the DB cluster will fail if the DB major version is past its end of standard support date.

    </note>
    

    You can use this setting to enroll your DB cluster into Amazon RDS Extended Support. With RDS Extended Support, you can run the selected major engine version on your DB cluster past the end of standard support for that engine version. For more information, see the following sections:

    • Amazon Aurora - [Using Amazon RDS Extended Support] in the *Amazon Aurora User Guide*

    • Amazon RDS - [Using Amazon RDS Extended Support] in the *Amazon RDS User Guide*

    Valid for Cluster Type: Aurora DB clusters and Multi-AZ DB clusters

    Valid Values: ‘open-source-rds-extended-support | open-source-rds-extended-support-disabled`

    Default: ‘open-source-rds-extended-support`

    [1]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/extended-support.html [2]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/extended-support.html

  • :source_region (String)

    The source region of the snapshot. This is only needed when the shapshot is encrypted and in a different region.

Returns:



975
976
977
978
979
980
981
982
983
984
# File 'lib/aws-sdk-rds/resource.rb', line 975

def create_db_cluster(options = {})
  resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
    @client.create_db_cluster(options)
  end
  DBCluster.new(
    id: resp.data.db_cluster.db_cluster_identifier,
    data: resp.data.db_cluster,
    client: @client
  )
end

#create_db_cluster_parameter_group(options = {}) ⇒ DBClusterParameterGroup

Examples:

Request syntax with placeholder values


dbclusterparametergroup = rds.create_db_cluster_parameter_group({
  db_cluster_parameter_group_name: "String", # required
  db_parameter_group_family: "String", # required
  description: "String", # required
  tags: [
    {
      key: "String",
      value: "String",
    },
  ],
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :db_cluster_parameter_group_name (required, String)

    The name of the DB cluster parameter group.

    Constraints:

    • Must not match the name of an existing DB cluster parameter group.

    ^

    <note markdown=“1”> This value is stored as a lowercase string.

    </note>
    
  • :db_parameter_group_family (required, String)

    The DB cluster parameter group family name. A DB cluster parameter group can be associated with one and only one DB cluster parameter group family, and can be applied only to a DB cluster running a database engine and engine version compatible with that DB cluster parameter group family.

    **Aurora MySQL**

    Example: ‘aurora-mysql5.7`, `aurora-mysql8.0`

    **Aurora PostgreSQL**

    Example: ‘aurora-postgresql14`

    **RDS for MySQL**

    Example: ‘mysql8.0`

    **RDS for PostgreSQL**

    Example: ‘postgres13`

    To list all of the available parameter group families for a DB engine, use the following command:

    ‘aws rds describe-db-engine-versions –query “DBEngineVersions[].DBParameterGroupFamily” –engine <engine>`

    For example, to list all of the available parameter group families for the Aurora PostgreSQL DB engine, use the following command:

    ‘aws rds describe-db-engine-versions –query “DBEngineVersions[].DBParameterGroupFamily” –engine aurora-postgresql`

    <note markdown=“1”> The output contains duplicates.

    </note>
    

    The following are the valid DB engine values:

    • ‘aurora-mysql`

    • ‘aurora-postgresql`

    • ‘mysql`

    • ‘postgres`

  • :description (required, String)

    The description for the DB cluster parameter group.

  • :tags (Array<Types::Tag>)

    Tags to assign to the DB cluster parameter group.

Returns:



1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
# File 'lib/aws-sdk-rds/resource.rb', line 1066

def create_db_cluster_parameter_group(options = {})
  resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
    @client.create_db_cluster_parameter_group(options)
  end
  DBClusterParameterGroup.new(
    name: resp.data.db_cluster_parameter_group.db_cluster_parameter_group_name,
    data: resp.data.db_cluster_parameter_group,
    client: @client
  )
end

#create_db_instance(options = {}) ⇒ DBInstance

Examples:

Request syntax with placeholder values


dbinstance = rds.create_db_instance({
  db_name: "String",
  db_instance_identifier: "String", # required
  allocated_storage: 1,
  db_instance_class: "String", # required
  engine: "String", # required
  master_username: "String",
  master_user_password: "String",
  db_security_groups: ["String"],
  vpc_security_group_ids: ["String"],
  availability_zone: "String",
  db_subnet_group_name: "String",
  preferred_maintenance_window: "String",
  db_parameter_group_name: "String",
  backup_retention_period: 1,
  preferred_backup_window: "String",
  port: 1,
  multi_az: false,
  engine_version: "String",
  auto_minor_version_upgrade: false,
  license_model: "String",
  iops: 1,
  option_group_name: "String",
  character_set_name: "String",
  nchar_character_set_name: "String",
  publicly_accessible: false,
  tags: [
    {
      key: "String",
      value: "String",
    },
  ],
  db_cluster_identifier: "String",
  storage_type: "String",
  tde_credential_arn: "String",
  tde_credential_password: "String",
  storage_encrypted: false,
  kms_key_id: "String",
  domain: "String",
  domain_fqdn: "String",
  domain_ou: "String",
  domain_auth_secret_arn: "String",
  domain_dns_ips: ["String"],
  copy_tags_to_snapshot: false,
  monitoring_interval: 1,
  monitoring_role_arn: "String",
  domain_iam_role_name: "String",
  promotion_tier: 1,
  timezone: "String",
  enable_iam_database_authentication: false,
  enable_performance_insights: false,
  performance_insights_kms_key_id: "String",
  performance_insights_retention_period: 1,
  enable_cloudwatch_logs_exports: ["String"],
  processor_features: [
    {
      name: "String",
      value: "String",
    },
  ],
  deletion_protection: false,
  max_allocated_storage: 1,
  enable_customer_owned_ip: false,
  custom_iam_instance_profile: "String",
  backup_target: "String",
  network_type: "String",
  storage_throughput: 1,
  manage_master_user_password: false,
  master_user_secret_kms_key_id: "String",
  ca_certificate_identifier: "String",
  db_system_id: "String",
  dedicated_log_volume: false,
  multi_tenant: false,
  engine_lifecycle_support: "String",
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :db_name (String)

    The meaning of this parameter differs according to the database engine you use.

    Amazon Aurora MySQL

    : The name of the database to create when the primary DB instance of

    the Aurora MySQL DB cluster is created. If this parameter isn't
    specified for an Aurora MySQL DB cluster, no database is created in
    the DB cluster.
    
    Constraints:
    
    * Must contain 1 to 64 alphanumeric characters.
    
    * Must begin with a letter. Subsequent characters can be letters,
      underscores, or digits (0-9).
    
    * Can't be a word reserved by the database engine.
    

    Amazon Aurora PostgreSQL

    : The name of the database to create when the primary DB instance of

    the Aurora PostgreSQL DB cluster is created. A database named
    `postgres` is always created. If this parameter is specified, an
    additional database with this name is created.
    
    Constraints:
    
    * It must contain 1 to 63 alphanumeric characters.
    
    * Must begin with a letter. Subsequent characters can be letters,
      underscores, or digits (0 to 9).
    
    * Can't be a word reserved by the database engine.
    

    Amazon RDS Custom for Oracle

    : The Oracle System ID (SID) of the created RDS Custom DB instance. If

    you don't specify a value, the default value is `ORCL` for non-CDBs
    and `RDSCDB` for CDBs.
    
    Default: `ORCL`
    
    Constraints:
    
    * Must contain 1 to 8 alphanumeric characters.
    
    * Must contain a letter.
    
    * Can't be a word reserved by the database engine.
    

    Amazon RDS Custom for SQL Server

    : Not applicable. Must be null.

    RDS for Db2

    : The name of the database to create when the DB instance is created.

    If this parameter isn't specified, no database is created in the DB
    instance. In some cases, we recommend that you don't add a database
    name. For more information, see [Additional considerations][1] in
    the *Amazon RDS User Guide*.
    
    Constraints:
    
    * Must contain 1 to 64 letters or numbers.
    
    * Must begin with a letter. Subsequent characters can be letters,
      underscores, or digits (0-9).
    
    * Can't be a word reserved by the specified database engine.
    

    RDS for MariaDB

    : The name of the database to create when the DB instance is created.

    If this parameter isn't specified, no database is created in the DB
    instance.
    
    Constraints:
    
    * Must contain 1 to 64 letters or numbers.
    
    * Must begin with a letter. Subsequent characters can be letters,
      underscores, or digits (0-9).
    
    * Can't be a word reserved by the specified database engine.
    

    RDS for MySQL

    : The name of the database to create when the DB instance is created.

    If this parameter isn't specified, no database is created in the DB
    instance.
    
    Constraints:
    
    * Must contain 1 to 64 letters or numbers.
    
    * Must begin with a letter. Subsequent characters can be letters,
      underscores, or digits (0-9).
    
    * Can't be a word reserved by the specified database engine.
    

    RDS for Oracle

    : The Oracle System ID (SID) of the created DB instance. If you don’t

    specify a value, the default value is `ORCL`. You can't specify the
    string `null`, or any other reserved word, for `DBName`.
    
    Default: `ORCL`
    
    Constraints:
    
    * Can't be longer than 8 characters.
    
    ^
    

    RDS for PostgreSQL

    : The name of the database to create when the DB instance is created.

    A database named `postgres` is always created. If this parameter is
    specified, an additional database with this name is created.
    
    Constraints:
    
    * Must contain 1 to 63 letters, numbers, or underscores.
    
    * Must begin with a letter. Subsequent characters can be letters,
      underscores, or digits (0-9).
    
    * Can't be a word reserved by the specified database engine.
    

    RDS for SQL Server

    : Not applicable. Must be null.

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/db2-db-instance-prereqs.html#db2-prereqs-additional-considerations

  • :db_instance_identifier (required, String)

    The identifier for this DB instance. This parameter is stored as a lowercase string.

    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: ‘mydbinstance`

  • :allocated_storage (Integer)

    The amount of storage in gibibytes (GiB) to allocate for the DB instance.

    This setting doesn’t apply to Amazon Aurora DB instances. Aurora cluster volumes automatically grow as the amount of data in your database increases, though you are only charged for the space that you use in an Aurora cluster volume.

    Amazon RDS Custom

    : Constraints to the amount of storage for each storage type are the

    following:
    
    * General Purpose (SSD) storage (gp2, gp3): Must be an integer from
      40 to 65536 for RDS Custom for Oracle, 16384 for RDS Custom for
      SQL Server.
    
    * Provisioned IOPS storage (io1, io2): Must be an integer from 40 to
      65536 for RDS Custom for Oracle, 16384 for RDS Custom for SQL
      Server.
    

    RDS for Db2

    : Constraints to the amount of storage for each storage type are the

    following:
    
    * General Purpose (SSD) storage (gp3): Must be an integer from 20 to
      65536.
    
    * Provisioned IOPS storage (io1, io2): Must be an integer from 100
      to 65536.
    

    RDS for MariaDB

    : Constraints to the amount of storage for each storage type are the

    following:
    
    * General Purpose (SSD) storage (gp2, gp3): Must be an integer from
      20 to 65536.
    
    * Provisioned IOPS storage (io1, io2): Must be an integer from 100
      to 65536.
    
    * Magnetic storage (standard): Must be an integer from 5 to 3072.
    

    RDS for MySQL

    : Constraints to the amount of storage for each storage type are the

    following:
    
    * General Purpose (SSD) storage (gp2, gp3): Must be an integer from
      20 to 65536.
    
    * Provisioned IOPS storage (io1, io2): Must be an integer from 100
      to 65536.
    
    * Magnetic storage (standard): Must be an integer from 5 to 3072.
    

    RDS for Oracle

    : Constraints to the amount of storage for each storage type are the

    following:
    
    * General Purpose (SSD) storage (gp2, gp3): Must be an integer from
      20 to 65536.
    
    * Provisioned IOPS storage (io1, io2): Must be an integer from 100
      to 65536.
    
    * Magnetic storage (standard): Must be an integer from 10 to 3072.
    

    RDS for PostgreSQL

    : Constraints to the amount of storage for each storage type are the

    following:
    
    * General Purpose (SSD) storage (gp2, gp3): Must be an integer from
      20 to 65536.
    
    * Provisioned IOPS storage (io1, io2): Must be an integer from 100
      to 65536.
    
    * Magnetic storage (standard): Must be an integer from 5 to 3072.
    

    RDS for SQL Server

    : Constraints to the amount of storage for each storage type are the

    following:
    
    * General Purpose (SSD) storage (gp2, gp3):
    
      * Enterprise and Standard editions: Must be an integer from 20 to
        16384.
    
      * Web and Express editions: Must be an integer from 20 to 16384.
    * Provisioned IOPS storage (io1, io2):
    
      * Enterprise and Standard editions: Must be an integer from 100 to
        16384.
    
      * Web and Express editions: Must be an integer from 100 to 16384.
    * Magnetic storage (standard):
    
      * Enterprise and Standard editions: Must be an integer from 20 to
        1024.
    
      * Web and Express editions: Must be an integer from 20 to 1024.
    
  • :db_instance_class (required, String)

    The compute and memory capacity of the DB instance, for example ‘db.m5.large`. Not all DB instance classes are available in all Amazon Web Services Regions, or for all database engines. For the full list of DB instance classes, and availability for your engine, see [DB instance classes] in the *Amazon RDS User Guide* or [Aurora DB instance classes] in the *Amazon Aurora User Guide*.

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Concepts.DBInstanceClass.html [2]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/Concepts.DBInstanceClass.html

  • :engine (required, String)

    The database engine to use for this DB instance.

    Not every database engine is available in every Amazon Web Services Region.

    Valid Values:

    • ‘aurora-mysql` (for Aurora MySQL DB instances)

    • ‘aurora-postgresql` (for Aurora PostgreSQL DB instances)

    • ‘custom-oracle-ee` (for RDS Custom for Oracle DB instances)

    • ‘custom-oracle-ee-cdb` (for RDS Custom for Oracle DB instances)

    • ‘custom-oracle-se2` (for RDS Custom for Oracle DB instances)

    • ‘custom-oracle-se2-cdb` (for RDS Custom for Oracle DB instances)

    • ‘custom-sqlserver-ee` (for RDS Custom for SQL Server DB instances)

    • ‘custom-sqlserver-se` (for RDS Custom for SQL Server DB instances)

    • ‘custom-sqlserver-web` (for RDS Custom for SQL Server DB instances)

    • ‘custom-sqlserver-dev` (for RDS Custom for SQL Server DB instances)

    • ‘db2-ae`

    • ‘db2-se`

    • ‘mariadb`

    • ‘mysql`

    • ‘oracle-ee`

    • ‘oracle-ee-cdb`

    • ‘oracle-se2`

    • ‘oracle-se2-cdb`

    • ‘postgres`

    • ‘sqlserver-ee`

    • ‘sqlserver-se`

    • ‘sqlserver-ex`

    • ‘sqlserver-web`

  • :master_username (String)

    The name for the master user.

    This setting doesn’t apply to Amazon Aurora DB instances. The name for the master user is managed by the DB cluster.

    This setting is required for RDS DB instances.

    Constraints:

    • Must be 1 to 16 letters, numbers, or underscores.

    • First character must be a letter.

    • Can’t be a reserved word for the chosen database engine.

  • :master_user_password (String)

    The password for the master user.

    This setting doesn’t apply to Amazon Aurora DB instances. The password for the master user is managed by the DB cluster.

    Constraints:

    • Can’t be specified if ‘ManageMasterUserPassword` is turned on.

    • Can include any printable ASCII character except “/”, “”“, or ”@“. For RDS for Oracle, can’t include the ”&amp;“ (ampersand) or the ”‘“ (single quotes) character.

    Length Constraints:

    • RDS for Db2 - Must contain from 8 to 255 characters.

    • RDS for MariaDB - Must contain from 8 to 41 characters.

    • RDS for Microsoft SQL Server - Must contain from 8 to 128 characters.

    • RDS for MySQL - Must contain from 8 to 41 characters.

    • RDS for Oracle - Must contain from 8 to 30 characters.

    • RDS for PostgreSQL - Must contain from 8 to 128 characters.

  • :db_security_groups (Array<String>)

    A list of DB security groups to associate with this DB instance.

    This setting applies to the legacy EC2-Classic platform, which is no longer used to create new DB instances. Use the ‘VpcSecurityGroupIds` setting instead.

  • :vpc_security_group_ids (Array<String>)

    A list of Amazon EC2 VPC security groups to associate with this DB instance.

    This setting doesn’t apply to Amazon Aurora DB instances. The associated list of EC2 VPC security groups is managed by the DB cluster.

    Default: The default EC2 VPC security group for the DB subnet group’s VPC.

  • :availability_zone (String)

    The Availability Zone (AZ) where the database will be created. For information on Amazon Web Services Regions and Availability Zones, see [Regions and Availability Zones].

    For Amazon Aurora, each Aurora DB cluster hosts copies of its storage in three separate Availability Zones. Specify one of these Availability Zones. Aurora automatically chooses an appropriate Availability Zone if you don’t specify one.

    Default: A random, system-chosen Availability Zone in the endpoint’s Amazon Web Services Region.

    Constraints:

    • The ‘AvailabilityZone` parameter can’t be specified if the DB instance is a Multi-AZ deployment.

    • The specified Availability Zone must be in the same Amazon Web Services Region as the current endpoint.

    Example: ‘us-east-1d`

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Concepts.RegionsAndAvailabilityZones.html

  • :db_subnet_group_name (String)

    A DB subnet group to associate with this DB instance.

    Constraints:

    • Must match the name of an existing DB subnet group.

    ^

    Example: ‘mydbsubnetgroup`

  • :preferred_maintenance_window (String)

    The time range each week during which system maintenance can occur. For more information, see [Amazon RDS Maintenance Window] in the *Amazon RDS User Guide.*

    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.

    Constraints:

    • Must be in the format ‘ddd:hh24:mi-ddd:hh24:mi`.

    • The day values must be ‘mon | tue | wed | thu | fri | sat | sun`.

    • Must be in Universal Coordinated Time (UTC).

    • Must not conflict with the preferred backup window.

    • Must be at least 30 minutes.

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_UpgradeDBInstance.Maintenance.html#Concepts.DBMaintenance

  • :db_parameter_group_name (String)

    The name of the DB parameter group to associate with this DB instance. If you don’t specify a value, then Amazon RDS uses the default DB parameter group for the specified DB engine and version.

    This setting doesn’t apply to RDS Custom DB instances.

    Constraints:

    • Must be 1 to 255 letters, numbers, or hyphens.

    • The first character must be a letter.

    • Can’t end with a hyphen or contain two consecutive hyphens.

  • :backup_retention_period (Integer)

    The number of days for which automated backups are retained. Setting this parameter to a positive number enables backups. Setting this parameter to ‘0` disables automated backups.

    This setting doesn’t apply to Amazon Aurora DB instances. The retention period for automated backups is managed by the DB cluster.

    Default: ‘1`

    Constraints:

    • Must be a value from 0 to 35.

    • Can’t be set to 0 if the DB instance is a source to read replicas.

    • Can’t be set to 0 for an RDS Custom for Oracle DB instance.

  • :preferred_backup_window (String)

    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. For more information, see [Backup window] in the *Amazon RDS User Guide*.

    This setting doesn’t apply to Amazon Aurora DB instances. The daily time range for creating automated backups is managed by the DB cluster.

    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.

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_WorkingWithAutomatedBackups.html#USER_WorkingWithAutomatedBackups.BackupWindow

  • :port (Integer)

    The port number on which the database accepts connections.

    This setting doesn’t apply to Aurora DB instances. The port number is managed by the cluster.

    Valid Values: ‘1150-65535`

    Default:

    • RDS for Db2 - ‘50000`

    • RDS for MariaDB - ‘3306`

    • RDS for Microsoft SQL Server - ‘1433`

    • RDS for MySQL - ‘3306`

    • RDS for Oracle - ‘1521`

    • RDS for PostgreSQL - ‘5432`

    Constraints:

    • For RDS for Microsoft SQL Server, the value can’t be ‘1234`, `1434`, `3260`, `3343`, `3389`, `47001`, or `49152-49156`.

    ^

  • :multi_az (Boolean)

    Specifies whether the DB instance is a Multi-AZ deployment. You can’t set the ‘AvailabilityZone` parameter if the DB instance is a Multi-AZ deployment.

    This setting doesn’t apply to the following DB instances:

    • Amazon Aurora (DB instance Availability Zones (AZs) are managed by the DB cluster.)

    • RDS Custom

  • :engine_version (String)

    The version number of the database engine to use.

    This setting doesn’t apply to Amazon Aurora DB instances. The version number of the database engine the DB instance uses is managed by the DB cluster.

    For a list of valid engine versions, use the ‘DescribeDBEngineVersions` operation.

    The following are the database engines and links to information about the major and minor versions that are available with Amazon RDS. Not every database engine is available for every Amazon Web Services Region.

    Amazon RDS Custom for Oracle

    : A custom engine version (CEV) that you have previously created. This

    setting is required for RDS Custom for Oracle. The CEV name has the
    following format: 19.*customized\_string*. A valid CEV name is
    `19.my_cev1`. For more information, see [ Creating an RDS Custom for
    Oracle DB instance][1] in the *Amazon RDS User Guide*.
    

    Amazon RDS Custom for SQL Server

    : See [RDS Custom for SQL Server general requirements] in the

    *Amazon RDS User Guide*.
    

    RDS for Db2

    : For information, see [Db2 on Amazon RDS versions] in the *Amazon

    RDS User Guide*.
    

    RDS for MariaDB

    : For information, see [MariaDB on Amazon RDS versions] in the

    *Amazon RDS User Guide*.
    

    RDS for Microsoft SQL Server

    : For information, see [Microsoft SQL Server versions on Amazon

    RDS][5] in the *Amazon RDS User Guide*.
    

    RDS for MySQL

    : For information, see [MySQL on Amazon RDS versions] in the

    *Amazon RDS User Guide*.
    

    RDS for Oracle

    : For information, see [Oracle Database Engine release notes] in

    the *Amazon RDS User Guide*.
    

    RDS for PostgreSQL

    : For information, see [Amazon RDS for PostgreSQL versions and

    extensions][8] in the *Amazon RDS User Guide*.
    

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/custom-creating.html#custom-creating.create [2]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/custom-reqs-limits-MS.html [3]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_Db2.html#Db2.Concepts.VersionMgmt [4]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_MariaDB.html#MariaDB.Concepts.VersionMgmt [5]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_SQLServer.html#SQLServer.Concepts.General.VersionSupport [6]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_MySQL.html#MySQL.Concepts.VersionMgmt [7]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Appendix.Oracle.PatchComposition.html [8]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_PostgreSQL.html#PostgreSQL.Concepts

  • :auto_minor_version_upgrade (Boolean)

    Specifies whether minor engine upgrades are applied automatically to the DB instance during the maintenance window. By default, minor engine upgrades are applied automatically.

    If you create an RDS Custom DB instance, you must set ‘AutoMinorVersionUpgrade` to `false`.

  • :license_model (String)

    The license model information for this DB instance.

    <note markdown=“1”> License models for RDS for Db2 require additional configuration. The Bring Your Own License (BYOL) model requires a custom parameter group and an Amazon Web Services License Manager self-managed license. The Db2 license through Amazon Web Services Marketplace model requires an Amazon Web Services Marketplace subscription. For more information, see [Amazon RDS for Db2 licensing options] in the *Amazon RDS User Guide*.

    The default for RDS for Db2 is `bring-your-own-license`.
    
    </note>
    

    This setting doesn’t apply to Amazon Aurora or RDS Custom DB instances.

    Valid Values:

    • RDS for Db2 - ‘bring-your-own-license | marketplace-license`

    • RDS for MariaDB - ‘general-public-license`

    • RDS for Microsoft SQL Server - ‘license-included`

    • RDS for MySQL - ‘general-public-license`

    • RDS for Oracle - ‘bring-your-own-license | license-included`

    • RDS for PostgreSQL - ‘postgresql-license`

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/db2-licensing.html

  • :iops (Integer)

    The amount of Provisioned IOPS (input/output operations per second) to initially allocate for the DB instance. For information about valid IOPS values, see [Amazon RDS DB instance storage] in the *Amazon RDS User Guide*.

    This setting doesn’t apply to Amazon Aurora DB instances. Storage is managed by the DB cluster.

    Constraints:

    • For RDS for Db2, MariaDB, MySQL, Oracle, and PostgreSQL - Must be a multiple between .5 and 50 of the storage amount for the DB instance.

    • For RDS for SQL Server - Must be a multiple between 1 and 50 of the storage amount for the DB instance.

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_Storage.html

  • :option_group_name (String)

    The option group to associate the DB instance with.

    Permanent options, such as the TDE option for Oracle Advanced Security TDE, can’t be removed from an option group. Also, that option group can’t be removed from a DB instance after it is associated with a DB instance.

    This setting doesn’t apply to Amazon Aurora or RDS Custom DB instances.

  • :character_set_name (String)

    For supported engines, the character set (‘CharacterSet`) to associate the DB instance with.

    This setting doesn’t apply to the following DB instances:

    • Amazon Aurora - The character set is managed by the DB cluster. For more information, see ‘CreateDBCluster`.

    • RDS Custom - However, if you need to change the character set, you can change it on the database itself.

  • :nchar_character_set_name (String)

    The name of the NCHAR character set for the Oracle DB instance.

    This setting doesn’t apply to RDS Custom DB instances.

  • :publicly_accessible (Boolean)

    Specifies whether the DB instance is publicly accessible.

    When the DB instance is publicly accessible and you connect from outside of the DB instance’s virtual private cloud (VPC), its Domain Name System (DNS) endpoint resolves to the public IP address. When you connect from within the same VPC as the DB instance, the endpoint resolves to the private IP address. Access to the DB instance is ultimately controlled by the security group it uses. That public access is not permitted if the security group assigned to the DB instance doesn’t permit it.

    When the DB instance isn’t publicly accessible, it is an internal DB instance with a DNS name that resolves to a private IP address.

    Default: The default behavior varies depending on whether ‘DBSubnetGroupName` is specified.

    If ‘DBSubnetGroupName` isn’t specified, and ‘PubliclyAccessible` isn’t specified, the following applies:

    • If the default VPC in the target Region doesn’t have an internet gateway attached to it, the DB instance is private.

    • If the default VPC in the target Region has an internet gateway attached to it, the DB instance is public.

    If ‘DBSubnetGroupName` is specified, and `PubliclyAccessible` isn’t specified, the following applies:

    • If the subnets are part of a VPC that doesn’t have an internet gateway attached to it, the DB instance is private.

    • If the subnets are part of a VPC that has an internet gateway attached to it, the DB instance is public.

  • :tags (Array<Types::Tag>)

    Tags to assign to the DB instance.

  • :db_cluster_identifier (String)

    The identifier of the DB cluster that this DB instance will belong to.

    This setting doesn’t apply to RDS Custom DB instances.

  • :storage_type (String)

    The storage type to associate with the DB instance.

    If you specify ‘io1`, `io2`, or `gp3`, you must also include a value for the `Iops` parameter.

    This setting doesn’t apply to Amazon Aurora DB instances. Storage is managed by the DB cluster.

    Valid Values: ‘gp2 | gp3 | io1 | io2 | standard`

    Default: ‘io1`, if the `Iops` parameter is specified. Otherwise, `gp2`.

  • :tde_credential_arn (String)

    The ARN from the key store with which to associate the instance for TDE encryption.

    This setting doesn’t apply to Amazon Aurora or RDS Custom DB instances.

  • :tde_credential_password (String)

    The password for the given ARN from the key store in order to access the device.

    This setting doesn’t apply to RDS Custom DB instances.

  • :storage_encrypted (Boolean)

    Specifes whether the DB instance is encrypted. By default, it isn’t encrypted.

    For RDS Custom DB instances, either enable this setting or leave it unset. Otherwise, Amazon RDS reports an error.

    This setting doesn’t apply to Amazon Aurora DB instances. The encryption for DB instances is managed by the DB cluster.

  • :kms_key_id (String)

    The Amazon Web Services KMS key identifier for an encrypted DB instance.

    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.

    This setting doesn’t apply to Amazon Aurora DB instances. The Amazon Web Services KMS key identifier is managed by the DB cluster. For more information, see ‘CreateDBCluster`.

    If ‘StorageEncrypted` is enabled, and you do not specify a value for the `KmsKeyId` parameter, then Amazon RDS uses 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.

    For Amazon RDS Custom, a KMS key is required for DB instances. For most RDS engines, if you leave this parameter empty while enabling ‘StorageEncrypted`, the engine uses the default KMS key. However, RDS Custom doesn’t use the default key when this parameter is empty. You must explicitly specify a key.

  • :domain (String)

    The Active Directory directory ID to create the DB instance in. Currently, you can create only Db2, MySQL, Microsoft SQL Server, Oracle, and PostgreSQL DB instances in an Active Directory Domain.

    For more information, see [ Kerberos Authentication] in the *Amazon RDS User Guide*.

    This setting doesn’t apply to the following DB instances:

    • Amazon Aurora (The domain is managed by the DB cluster.)

    • RDS Custom

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/kerberos-authentication.html

  • :domain_fqdn (String)

    The fully qualified domain name (FQDN) of an Active Directory domain.

    Constraints:

    • Can’t be longer than 64 characters.

    ^

    Example: ‘mymanagedADtest.mymanagedAD.mydomain`

  • :domain_ou (String)

    The Active Directory organizational unit for your DB instance to join.

    Constraints:

    • Must be in the distinguished name format.

    • Can’t be longer than 64 characters.

    Example: ‘OU=mymanagedADtestOU,DC=mymanagedADtest,DC=mymanagedAD,DC=mydomain`

  • :domain_auth_secret_arn (String)

    The ARN for the Secrets Manager secret with the credentials for the user joining the domain.

    Example: ‘arn:aws:secretsmanager:region:account-number:secret:myselfmanagedADtestsecret-123456`

  • :domain_dns_ips (Array<String>)

    The IPv4 DNS IP addresses of your primary and secondary Active Directory domain controllers.

    Constraints:

    • Two IP addresses must be provided. If there isn’t a secondary domain controller, use the IP address of the primary domain controller for both entries in the list.

    ^

    Example: ‘123.124.125.126,234.235.236.237`

  • :copy_tags_to_snapshot (Boolean)

    Specifies whether to copy tags from the DB instance to snapshots of the DB instance. By default, tags are not copied.

    This setting doesn’t apply to Amazon Aurora DB instances. Copying tags to snapshots is managed by the DB cluster. Setting this value for an Aurora DB instance has no effect on the DB cluster setting.

  • :monitoring_interval (Integer)

    The interval, in seconds, between points when Enhanced Monitoring metrics are collected for the DB instance. To disable collection of Enhanced Monitoring metrics, specify ‘0`.

    If ‘MonitoringRoleArn` is specified, then you must set `MonitoringInterval` to a value other than `0`.

    This setting doesn’t apply to RDS Custom DB instances.

    Valid Values: ‘0 | 1 | 5 | 10 | 15 | 30 | 60`

    Default: ‘0`

  • :monitoring_role_arn (String)

    The ARN for the IAM role that permits RDS to send enhanced monitoring metrics to Amazon CloudWatch Logs. For example, ‘arn:aws:iam:123456789012:role/emaccess`. For information on creating a monitoring role, see [Setting Up and Enabling Enhanced Monitoring] in the *Amazon RDS User Guide*.

    If ‘MonitoringInterval` is set to a value other than `0`, then you must supply a `MonitoringRoleArn` value.

    This setting doesn’t apply to RDS Custom DB instances.

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Monitoring.OS.html#USER_Monitoring.OS.Enabling

  • :domain_iam_role_name (String)

    The name of the IAM role to use when making API calls to the Directory Service.

    This setting doesn’t apply to the following DB instances:

    • Amazon Aurora (The domain is managed by the DB cluster.)

    • RDS Custom

  • :promotion_tier (Integer)

    The order of priority in which an Aurora Replica is promoted to the primary instance after a failure of the existing primary instance. For more information, see [ Fault Tolerance for an Aurora DB Cluster] in the *Amazon Aurora User Guide*.

    This setting doesn’t apply to RDS Custom DB instances.

    Default: ‘1`

    Valid Values: ‘0 - 15`

    [1]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/Concepts.AuroraHighAvailability.html#Aurora.Managing.FaultTolerance

  • :timezone (String)

    The time zone of the DB instance. The time zone parameter is currently supported only by [RDS for Db2] and [RDS for SQL Server].

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/db2-time-zone [2]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_SQLServer.html#SQLServer.Concepts.General.TimeZone

  • :enable_iam_database_authentication (Boolean)

    Specifies 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 for MySQL and PostgreSQL] in the *Amazon RDS User Guide*.

    This setting doesn’t apply to the following DB instances:

    • Amazon Aurora (Mapping Amazon Web Services IAM accounts to database accounts is managed by the DB cluster.)

    • RDS Custom

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/UsingWithRDS.IAMDBAuth.html

  • :enable_performance_insights (Boolean)

    Specifies whether to enable Performance Insights for the DB instance. For more information, see [Using Amazon Performance Insights] in the *Amazon RDS User Guide*.

    This setting doesn’t apply to RDS Custom DB instances.

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_PerfInsights.html

  • :performance_insights_kms_key_id (String)

    The Amazon Web Services KMS key identifier for encryption of Performance Insights data.

    The Amazon Web Services KMS key identifier is the key ARN, key ID, alias ARN, or alias name for the KMS key.

    If you don’t specify a value for ‘PerformanceInsightsKMSKeyId`, then Amazon RDS uses 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.

    This setting doesn’t apply to RDS Custom DB instances.

  • :performance_insights_retention_period (Integer)

    The number of days to retain Performance Insights data.

    This setting doesn’t apply to RDS Custom DB instances.

    Valid Values:

    • ‘7`

    • month * 31, where month is a number of months from 1-23. Examples: ‘93` (3 months * 31), `341` (11 months * 31), `589` (19 months * 31)

    • ‘731`

    Default: ‘7` days

    If you specify a retention period that isn’t valid, such as ‘94`, Amazon RDS returns an error.

  • :enable_cloudwatch_logs_exports (Array<String>)

    The list of log types to enable for exporting to CloudWatch Logs. For more information, see [ Publishing Database Logs to Amazon CloudWatch Logs] in the *Amazon RDS User Guide*.

    This setting doesn’t apply to the following DB instances:

    • Amazon Aurora (CloudWatch Logs exports are managed by the DB cluster.)

    • RDS Custom

    The following values are valid for each DB engine:

    • RDS for Db2 - ‘diag.log | notify.log`

    • RDS for MariaDB - ‘audit | error | general | slowquery`

    • RDS for Microsoft SQL Server - ‘agent | error`

    • RDS for MySQL - ‘audit | error | general | slowquery`

    • RDS for Oracle - ‘alert | audit | listener | trace | oemagent`

    • RDS for PostgreSQL - ‘postgresql | upgrade`

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_LogAccess.html#USER_LogAccess.Procedural.UploadtoCloudWatch

  • :processor_features (Array<Types::ProcessorFeature>)

    The number of CPU cores and the number of threads per core for the DB instance class of the DB instance.

    This setting doesn’t apply to Amazon Aurora or RDS Custom DB instances.

  • :deletion_protection (Boolean)

    Specifies whether the DB instance has deletion protection enabled. The database can’t be deleted when deletion protection is enabled. By default, deletion protection isn’t enabled. For more information, see [ Deleting a DB Instance].

    This setting doesn’t apply to Amazon Aurora DB instances. You can enable or disable deletion protection for the DB cluster. For more information, see ‘CreateDBCluster`. DB instances in a DB cluster can be deleted even when deletion protection is enabled for the DB cluster.

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_DeleteInstance.html

  • :max_allocated_storage (Integer)

    The upper limit in gibibytes (GiB) to which Amazon RDS can automatically scale the storage of the DB instance.

    For more information about this setting, including limitations that apply to it, see [ Managing capacity automatically with Amazon RDS storage autoscaling] in the *Amazon RDS User Guide*.

    This setting doesn’t apply to the following DB instances:

    • Amazon Aurora (Storage is managed by the DB cluster.)

    • RDS Custom

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_PIOPS.StorageTypes.html#USER_PIOPS.Autoscaling

  • :enable_customer_owned_ip (Boolean)

    Specifies whether to enable a customer-owned IP address (CoIP) for an RDS on Outposts DB instance.

    A CoIP provides local or external connectivity to resources in your Outpost subnets through your on-premises network. For some use cases, a CoIP can provide lower latency for connections to the DB instance from outside of its virtual private cloud (VPC) on your local network.

    For more information about RDS on Outposts, see [Working with Amazon RDS on Amazon Web Services Outposts] in the *Amazon RDS User Guide*.

    For more information about CoIPs, see [Customer-owned IP addresses] in the *Amazon Web Services Outposts User Guide*.

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/rds-on-outposts.html [2]: docs.aws.amazon.com/outposts/latest/userguide/routing.html#ip-addressing

  • :custom_iam_instance_profile (String)

    The instance profile associated with the underlying Amazon EC2 instance of an RDS Custom DB instance.

    This setting is required for RDS Custom.

    Constraints:

    • The profile must exist in your account.

    • The profile must have an IAM role that Amazon EC2 has permissions to assume.

    • The instance profile name and the associated IAM role name must start with the prefix ‘AWSRDSCustom`.

    For the list of permissions required for the IAM role, see [ Configure IAM and your VPC] in the *Amazon RDS User Guide*.

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/custom-setup-orcl.html#custom-setup-orcl.iam-vpc

  • :backup_target (String)

    The location for storing automated backups and manual snapshots.

    Valid Values:

    • ‘outposts` (Amazon Web Services Outposts)

    • ‘region` (Amazon Web Services Region)

    Default: ‘region`

    For more information, see [Working with Amazon RDS on Amazon Web Services Outposts] in the *Amazon RDS User Guide*.

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/rds-on-outposts.html

  • :network_type (String)

    The network type of the DB instance.

    The network type is determined by the ‘DBSubnetGroup` specified for the DB instance. 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 RDS User Guide.*

    Valid Values: ‘IPV4 | DUAL`

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_VPC.WorkingWithRDSInstanceinaVPC.html

  • :storage_throughput (Integer)

    The storage throughput value for the DB instance.

    This setting applies only to the ‘gp3` storage type.

    This setting doesn’t apply to Amazon Aurora or RDS Custom DB instances.

  • :manage_master_user_password (Boolean)

    Specifies 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.*

    Constraints:

    • Can’t manage the master user password with Amazon Web Services Secrets Manager if ‘MasterUserPassword` is specified.

    ^

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/rds-secrets-manager.html

  • :master_user_secret_kms_key_id (String)

    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 instance.

    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.

  • :ca_certificate_identifier (String)

    The CA certificate identifier to use for the DB instance’s server certificate.

    This setting doesn’t apply to RDS Custom DB instances.

    For more information, see [Using SSL/TLS to encrypt a connection to a DB instance] in the *Amazon RDS User Guide* and [ Using SSL/TLS to encrypt a connection to a DB cluster] in the *Amazon Aurora User Guide*.

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/UsingWithRDS.SSL.html [2]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/UsingWithRDS.SSL.html

  • :db_system_id (String)

    The Oracle system identifier (SID), which is the name of the Oracle database instance that manages your database files. In this context, the term “Oracle database instance” refers exclusively to the system global area (SGA) and Oracle background processes. If you don’t specify a SID, the value defaults to ‘RDSCDB`. The Oracle SID is also the name of your CDB.

  • :dedicated_log_volume (Boolean)

    Indicates whether the DB instance has a dedicated log volume (DLV) enabled.

  • :multi_tenant (Boolean)

    Specifies whether to use the multi-tenant configuration or the single-tenant configuration (default). This parameter only applies to RDS for Oracle container database (CDB) engines.

    Note the following restrictions:

    • The DB engine that you specify in the request must support the multi-tenant configuration. If you attempt to enable the multi-tenant configuration on a DB engine that doesn’t support it, the request fails.

    • If you specify the multi-tenant configuration when you create your DB instance, you can’t later modify this DB instance to use the single-tenant configuration.

  • :engine_lifecycle_support (String)

    The life cycle type for this DB instance.

    <note markdown=“1”> By default, this value is set to ‘open-source-rds-extended-support`, which enrolls your DB instance into Amazon RDS Extended Support. At the end of standard support, you can avoid charges for Extended Support by setting the value to `open-source-rds-extended-support-disabled`. In this case, creating the DB instance will fail if the DB major version is past its end of standard support date.

    </note>
    

    This setting applies only to RDS for MySQL and RDS for PostgreSQL. For Amazon Aurora DB instances, the life cycle type is managed by the DB cluster.

    You can use this setting to enroll your DB instance into Amazon RDS Extended Support. With RDS Extended Support, you can run the selected major engine version on your DB instance past the end of standard support for that engine version. For more information, see [Using Amazon RDS Extended Support] in the *Amazon RDS User Guide*.

    Valid Values: ‘open-source-rds-extended-support | open-source-rds-extended-support-disabled`

    Default: ‘open-source-rds-extended-support`

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/extended-support.html

Returns:



2390
2391
2392
2393
2394
2395
2396
2397
2398
2399
# File 'lib/aws-sdk-rds/resource.rb', line 2390

def create_db_instance(options = {})
  resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
    @client.create_db_instance(options)
  end
  DBInstance.new(
    id: resp.data.db_instance.db_instance_identifier,
    data: resp.data.db_instance,
    client: @client
  )
end

#create_db_parameter_group(options = {}) ⇒ DBParameterGroup

Examples:

Request syntax with placeholder values


dbparametergroup = rds.create_db_parameter_group({
  db_parameter_group_name: "String", # required
  db_parameter_group_family: "String", # required
  description: "String", # required
  tags: [
    {
      key: "String",
      value: "String",
    },
  ],
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :db_parameter_group_name (required, String)

    The name of the DB parameter group.

    Constraints:

    • Must be 1 to 255 letters, numbers, or hyphens.

    • First character must be a letter

    • Can’t end with a hyphen or contain two consecutive hyphens

    <note markdown=“1”> This value is stored as a lowercase string.

    </note>
    
  • :db_parameter_group_family (required, String)

    The DB parameter group family name. A DB parameter group can be associated with one and only one DB parameter group family, and can be applied only to a DB instance running a database engine and engine version compatible with that DB parameter group family.

    To list all of the available parameter group families for a DB engine, use the following command:

    ‘aws rds describe-db-engine-versions –query “DBEngineVersions[].DBParameterGroupFamily” –engine <engine>`

    For example, to list all of the available parameter group families for the MySQL DB engine, use the following command:

    ‘aws rds describe-db-engine-versions –query “DBEngineVersions[].DBParameterGroupFamily” –engine mysql`

    <note markdown=“1”> The output contains duplicates.

    </note>
    

    The following are the valid DB engine values:

    • ‘aurora-mysql`

    • ‘aurora-postgresql`

    • ‘db2-ae`

    • ‘db2-se`

    • ‘mysql`

    • ‘oracle-ee`

    • ‘oracle-ee-cdb`

    • ‘oracle-se2`

    • ‘oracle-se2-cdb`

    • ‘postgres`

    • ‘sqlserver-ee`

    • ‘sqlserver-se`

    • ‘sqlserver-ex`

    • ‘sqlserver-web`

  • :description (required, String)

    The description for the DB parameter group.

  • :tags (Array<Types::Tag>)

    Tags to assign to the DB parameter group.

Returns:



2485
2486
2487
2488
2489
2490
2491
2492
2493
2494
# File 'lib/aws-sdk-rds/resource.rb', line 2485

def create_db_parameter_group(options = {})
  resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
    @client.create_db_parameter_group(options)
  end
  DBParameterGroup.new(
    name: resp.data.db_parameter_group.db_parameter_group_name,
    data: resp.data.db_parameter_group,
    client: @client
  )
end

#create_db_security_group(options = {}) ⇒ DBSecurityGroup

Examples:

Request syntax with placeholder values


dbsecuritygroup = rds.create_db_security_group({
  db_security_group_name: "String", # required
  db_security_group_description: "String", # required
  tags: [
    {
      key: "String",
      value: "String",
    },
  ],
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :db_security_group_name (required, String)

    The name for the DB security group. This value is stored as a lowercase string.

    Constraints:

    • Must be 1 to 255 letters, numbers, or hyphens.

    • First character must be a letter

    • Can’t end with a hyphen or contain two consecutive hyphens

    • Must not be “Default”

    Example: ‘mysecuritygroup`

  • :db_security_group_description (required, String)

    The description for the DB security group.

  • :tags (Array<Types::Tag>)

    Tags to assign to the DB security group.

Returns:



2529
2530
2531
2532
2533
2534
2535
2536
2537
2538
# File 'lib/aws-sdk-rds/resource.rb', line 2529

def create_db_security_group(options = {})
  resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
    @client.create_db_security_group(options)
  end
  DBSecurityGroup.new(
    name: resp.data.db_security_group.db_security_group_name,
    data: resp.data.db_security_group,
    client: @client
  )
end

#create_db_subnet_group(options = {}) ⇒ DBSubnetGroup

Examples:

Request syntax with placeholder values


dbsubnetgroup = rds.create_db_subnet_group({
  db_subnet_group_name: "String", # required
  db_subnet_group_description: "String", # required
  subnet_ids: ["String"], # required
  tags: [
    {
      key: "String",
      value: "String",
    },
  ],
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :db_subnet_group_name (required, String)

    The name for the DB subnet group. This value is stored as a lowercase string.

    Constraints:

    • Must contain no more than 255 letters, numbers, periods, underscores, spaces, or hyphens.

    • Must not be default.

    • First character must be a letter.

    Example: ‘mydbsubnetgroup`

  • :db_subnet_group_description (required, String)

    The description for the DB subnet group.

  • :subnet_ids (required, Array<String>)

    The EC2 Subnet IDs for the DB subnet group.

  • :tags (Array<Types::Tag>)

    Tags to assign to the DB subnet group.

Returns:



2575
2576
2577
2578
2579
2580
2581
2582
2583
2584
# File 'lib/aws-sdk-rds/resource.rb', line 2575

def create_db_subnet_group(options = {})
  resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
    @client.create_db_subnet_group(options)
  end
  DBSubnetGroup.new(
    name: resp.data.db_subnet_group.db_subnet_group_name,
    data: resp.data.db_subnet_group,
    client: @client
  )
end

#create_event_subscription(options = {}) ⇒ EventSubscription

Examples:

Request syntax with placeholder values


eventsubscription = rds.create_event_subscription({
  subscription_name: "String", # required
  sns_topic_arn: "String", # required
  source_type: "String",
  event_categories: ["String"],
  source_ids: ["String"],
  enabled: false,
  tags: [
    {
      key: "String",
      value: "String",
    },
  ],
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :subscription_name (required, String)

    The name of the subscription.

    Constraints: The name must be less than 255 characters.

  • :sns_topic_arn (required, String)

    The Amazon Resource Name (ARN) of the SNS topic created for event notification. SNS automatically creates the ARN when you create a topic and subscribe to it.

    <note markdown=“1”> RDS doesn’t support FIFO (first in, first out) topics. For more information, see [Message ordering and deduplication (FIFO topics)] in the *Amazon Simple Notification Service Developer Guide*.

    </note>
    

    [1]: docs.aws.amazon.com/sns/latest/dg/sns-fifo-topics.html

  • :source_type (String)

    The type of source that is generating the events. For example, if you want to be notified of events generated by a DB instance, you set this parameter to ‘db-instance`. For RDS Proxy events, specify `db-proxy`. If this value isn’t specified, all events are returned.

    Valid Values:‘ db-instance | db-cluster | db-parameter-group | db-security-group | db-snapshot | db-cluster-snapshot | db-proxy | zero-etl | custom-engine-version | blue-green-deployment `

  • :event_categories (Array<String>)

    A list of event categories for a particular source type (‘SourceType`) that you want to subscribe to. You can see a list of the categories for a given source type in the “Amazon RDS event categories and event messages” section of the [ *Amazon RDS User Guide* ][1] or the [ *Amazon Aurora User Guide* ][2]. You can also see this list by using the `DescribeEventCategories` operation.

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Events.Messages.html [2]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/USER_Events.Messages.html

  • :source_ids (Array<String>)

    The list of identifiers of the event sources for which events are returned. If not specified, then all sources are included in the response. An identifier must begin with a letter and must contain only ASCII letters, digits, and hyphens. It can’t end with a hyphen or contain two consecutive hyphens.

    Constraints:

    • If ‘SourceIds` are supplied, `SourceType` must also be provided.

    • If the source type is a DB instance, a ‘DBInstanceIdentifier` value must be supplied.

    • If the source type is a DB cluster, a ‘DBClusterIdentifier` value must be supplied.

    • If the source type is a DB parameter group, a ‘DBParameterGroupName` value must be supplied.

    • If the source type is a DB security group, a ‘DBSecurityGroupName` value must be supplied.

    • If the source type is a DB snapshot, a ‘DBSnapshotIdentifier` value must be supplied.

    • If the source type is a DB cluster snapshot, a ‘DBClusterSnapshotIdentifier` value must be supplied.

    • If the source type is an RDS Proxy, a ‘DBProxyName` value must be supplied.

  • :enabled (Boolean)

    Specifies whether to activate the subscription. If the event notification subscription isn’t activated, the subscription is created but not active.

  • :tags (Array<Types::Tag>)

    A list of tags.

    For more information, see [Tagging Amazon RDS resources] in the *Amazon RDS User Guide* or [Tagging Amazon Aurora and Amazon RDS resources] in the *Amazon Aurora User Guide*.

    [1]: docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_Tagging.html [2]: docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/USER_Tagging.html

Returns:



2689
2690
2691
2692
2693
2694
2695
2696
2697
2698
# File 'lib/aws-sdk-rds/resource.rb', line 2689

def create_event_subscription(options = {})
  resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
    @client.create_event_subscription(options)
  end
  EventSubscription.new(
    name: resp.data.event_subscription.cust_subscription_id,
    data: resp.data.event_subscription,
    client: @client
  )
end

#create_option_group(options = {}) ⇒ OptionGroup

Examples:

Request syntax with placeholder values


optiongroup = rds.create_option_group({
  option_group_name: "String", # required
  engine_name: "String", # required
  major_engine_version: "String", # required
  option_group_description: "String", # required
  tags: [
    {
      key: "String",
      value: "String",
    },
  ],
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :option_group_name (required, String)

    Specifies the name of the option group to be created.

    Constraints:

    • Must be 1 to 255 letters, numbers, or hyphens

    • First character must be a letter

    • Can’t end with a hyphen or contain two consecutive hyphens

    Example: ‘myoptiongroup`

  • :engine_name (required, String)

    The name of the engine to associate this option group with.

    Valid Values:

    • ‘db2-ae`

    • ‘db2-se`

    • ‘mariadb`

    • ‘mysql`

    • ‘oracle-ee`

    • ‘oracle-ee-cdb`

    • ‘oracle-se2`

    • ‘oracle-se2-cdb`

    • ‘postgres`

    • ‘sqlserver-ee`

    • ‘sqlserver-se`

    • ‘sqlserver-ex`

    • ‘sqlserver-web`

  • :major_engine_version (required, String)

    Specifies the major version of the engine that this option group should be associated with.

  • :option_group_description (required, String)

    The description of the option group.

  • :tags (Array<Types::Tag>)

    Tags to assign to the option group.

Returns:



2765
2766
2767
2768
2769
2770
2771
2772
2773
2774
# File 'lib/aws-sdk-rds/resource.rb', line 2765

def create_option_group(options = {})
  resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
    @client.create_option_group(options)
  end
  OptionGroup.new(
    name: resp.data.option_group.option_group_name,
    data: resp.data.option_group,
    client: @client
  )
end

#db_cluster(id) ⇒ DBCluster

Parameters:

  • id (String)

Returns:



2857
2858
2859
2860
2861
2862
# File 'lib/aws-sdk-rds/resource.rb', line 2857

def db_cluster(id)
  DBCluster.new(
    id: id,
    client: @client
  )
end

#db_cluster_parameter_group(name) ⇒ DBClusterParameterGroup

Parameters:

  • name (String)

Returns:



2866
2867
2868
2869
2870
2871
# File 'lib/aws-sdk-rds/resource.rb', line 2866

def db_cluster_parameter_group(name)
  DBClusterParameterGroup.new(
    name: name,
    client: @client
  )
end

#db_cluster_parameter_groups(options = {}) ⇒ DBClusterParameterGroup::Collection

Examples:

Request syntax with placeholder values


db_cluster_parameter_groups = rds.db_cluster_parameter_groups({
  db_cluster_parameter_group_name: "String",
  filters: [
    {
      name: "String", # required
      values: ["String"], # required
    },
  ],
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :db_cluster_parameter_group_name (String)

    The name of a specific DB cluster parameter group to return details for.

    Constraints:

    • If supplied, must match the name of an existing DBClusterParameterGroup.

    ^

  • :filters (Array<Types::Filter>)

    This parameter isn’t currently supported.

Returns:



2898
2899
2900
2901
2902
2903
2904
2905
2906
2907
2908
2909
2910
2911
2912
2913
2914
2915
2916
# File 'lib/aws-sdk-rds/resource.rb', line 2898

def db_cluster_parameter_groups(options = {})
  batches = Enumerator.new do |y|
    resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
      @client.describe_db_cluster_parameter_groups(options)
    end
    resp.each_page do |page|
      batch = []
      page.data.db_cluster_parameter_groups.each do |d|
        batch << DBClusterParameterGroup.new(
          name: d.db_cluster_parameter_group_name,
          data: d,
          client: @client
        )
      end
      y.yield(batch)
    end
  end
  DBClusterParameterGroup::Collection.new(batches)
end

#db_clusters(options = {}) ⇒ DBCluster::Collection

Examples:

Request syntax with placeholder values


db_clusters = rds.db_clusters({
  db_cluster_identifier: "String",
  filters: [
    {
      name: "String", # required
      values: ["String"], # required
    },
  ],
  include_shared: false,
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :db_cluster_identifier (String)

    The user-supplied DB cluster identifier or the Amazon Resource Name (ARN) of the DB cluster. If this parameter is specified, information for only the specific DB cluster is returned. This parameter isn’t case-sensitive.

    Constraints:

    • If supplied, must match an existing DB cluster identifier.

    ^

  • :filters (Array<Types::Filter>)

    A filter that specifies one or more DB clusters to describe.

    Supported Filters:

    • ‘clone-group-id` - Accepts clone group identifiers. The results list only includes information about the DB clusters associated with these clone groups.

    • ‘db-cluster-id` - Accepts DB cluster identifiers and DB cluster Amazon Resource Names (ARNs). The results list only includes information about the DB clusters identified by these ARNs.

    • ‘db-cluster-resource-id` - Accepts DB cluster resource identifiers. The results list will only include information about the DB clusters identified by these DB cluster resource identifiers.

    • ‘domain` - Accepts Active Directory directory IDs. The results list only includes information about the DB clusters associated with these domains.

    • ‘engine` - Accepts engine names. The results list only includes information about the DB clusters for these engines.

  • :include_shared (Boolean)

    Specifies whether the output includes information about clusters shared from other Amazon Web Services accounts.

Returns:



2969
2970
2971
2972
2973
2974
2975
2976
2977
2978
2979
2980
2981
2982
2983
2984
2985
2986
2987
# File 'lib/aws-sdk-rds/resource.rb', line 2969

def db_clusters(options = {})
  batches = Enumerator.new do |y|
    resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
      @client.describe_db_clusters(options)
    end
    resp.each_page do |page|
      batch = []
      page.data.db_clusters.each do |d|
        batch << DBCluster.new(
          id: d.db_cluster_identifier,
          data: d,
          client: @client
        )
      end
      y.yield(batch)
    end
  end
  DBCluster::Collection.new(batches)
end

#db_engine(name) ⇒ DBEngine

Parameters:

  • name (String)

Returns:



2991
2992
2993
2994
2995
2996
# File 'lib/aws-sdk-rds/resource.rb', line 2991

def db_engine(name)
  DBEngine.new(
    name: name,
    client: @client
  )
end

#db_engine_version(engine_name, version) ⇒ DBEngineVersion

Parameters:

  • engine_name (String)
  • version (String)

Returns:



3001
3002
3003
3004
3005
3006
3007
# File 'lib/aws-sdk-rds/resource.rb', line 3001

def db_engine_version(engine_name, version)
  DBEngineVersion.new(
    engine_name: engine_name,
    version: version,
    client: @client
  )
end

#db_engine_versions(options = {}) ⇒ DBEngineVersion::Collection

Examples:

Request syntax with placeholder values


db_engine_versions = rds.db_engine_versions({
  engine: "String",
  engine_version: "String",
  db_parameter_group_family: "String",
  filters: [
    {
      name: "String", # required
      values: ["String"], # required
    },
  ],
  default_only: false,
  list_supported_character_sets: false,
  list_supported_timezones: false,
  include_all: false,
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :engine (String)

    The database engine to return version details for.

    Valid Values:

    • ‘aurora-mysql`

    • ‘aurora-postgresql`

    • ‘custom-oracle-ee`

    • ‘custom-oracle-ee-cdb`

    • ‘custom-oracle-se2`

    • ‘custom-oracle-se2-cdb`

    • ‘db2-ae`

    • ‘db2-se`

    • ‘mariadb`

    • ‘mysql`

    • ‘oracle-ee`

    • ‘oracle-ee-cdb`

    • ‘oracle-se2`

    • ‘oracle-se2-cdb`

    • ‘postgres`

    • ‘sqlserver-ee`

    • ‘sqlserver-se`

    • ‘sqlserver-ex`

    • ‘sqlserver-web`

  • :engine_version (String)

    A specific database engine version to return details for.

    Example: ‘5.1.49`

  • :db_parameter_group_family (String)

    The name of a specific DB parameter group family to return details for.

    Constraints:

    • If supplied, must match an existing DB parameter group family.

    ^

  • :filters (Array<Types::Filter>)

    A filter that specifies one or more DB engine versions to describe.

    Supported filters:

    • ‘db-parameter-group-family` - Accepts parameter groups family names. The results list only includes information about the DB engine versions for these parameter group families.

    • ‘engine` - Accepts engine names. The results list only includes information about the DB engine versions for these engines.

    • ‘engine-mode` - Accepts DB engine modes. The results list only includes information about the DB engine versions for these engine modes. Valid DB engine modes are the following:

      • ‘global`

      • ‘multimaster`

      • ‘parallelquery`

      • ‘provisioned`

      • ‘serverless`

    • ‘engine-version` - Accepts engine versions. The results list only includes information about the DB engine versions for these engine versions.

    • ‘status` - Accepts engine version statuses. The results list only includes information about the DB engine versions for these statuses. Valid statuses are the following:

      • ‘available`

      • ‘deprecated`

  • :default_only (Boolean)

    Specifies whether to return only the default version of the specified engine or the engine and major version combination.

  • :list_supported_character_sets (Boolean)

    Specifies whether to list the supported character sets for each engine version.

    If this parameter is enabled and the requested engine supports the ‘CharacterSetName` parameter for `CreateDBInstance`, the response includes a list of supported character sets for each engine version.

    For RDS Custom, the default is not to list supported character sets. If you enable this parameter, RDS Custom returns no results.

  • :list_supported_timezones (Boolean)

    Specifies whether to list the supported time zones for each engine version.

    If this parameter is enabled and the requested engine supports the ‘TimeZone` parameter for `CreateDBInstance`, the response includes a list of supported time zones for each engine version.

    For RDS Custom, the default is not to list supported time zones. If you enable this parameter, RDS Custom returns no results.

  • :include_all (Boolean)

    Specifies whether to also list the engine versions that aren’t available. The default is to list only available engine versions.

Returns:



3145
3146
3147
3148
3149
3150
3151
3152
3153
3154
3155
3156
3157
3158
3159
3160
3161
3162
3163
3164
# File 'lib/aws-sdk-rds/resource.rb', line 3145

def db_engine_versions(options = {})
  batches = Enumerator.new do |y|
    resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
      @client.describe_db_engine_versions(options)
    end
    resp.each_page do |page|
      batch = []
      page.data.db_engine_versions.each do |d|
        batch << DBEngineVersion.new(
          engine_name: d.engine,
          version: d.engine_version,
          data: d,
          client: @client
        )
      end
      y.yield(batch)
    end
  end
  DBEngineVersion::Collection.new(batches)
end

#db_instance(id) ⇒ DBInstance

Parameters:

  • id (String)

Returns:



3168
3169
3170
3171
3172
3173
# File 'lib/aws-sdk-rds/resource.rb', line 3168

def db_instance(id)
  DBInstance.new(
    id: id,
    client: @client
  )
end

#db_instances(options = {}) ⇒ DBInstance::Collection

Examples:

Request syntax with placeholder values


db_instances = rds.db_instances({
  db_instance_identifier: "String",
  filters: [
    {
      name: "String", # required
      values: ["String"], # required
    },
  ],
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :db_instance_identifier (String)

    The user-supplied instance identifier or the Amazon Resource Name (ARN) of the DB instance. If this parameter is specified, information from only the specific DB instance is returned. This parameter isn’t case-sensitive.

    Constraints:

    • If supplied, must match the identifier of an existing DB instance.

    ^

  • :filters (Array<Types::Filter>)

    A filter that specifies one or more DB instances to describe.

    Supported Filters:

    • ‘db-cluster-id` - Accepts DB cluster identifiers and DB cluster Amazon Resource Names (ARNs). The results list only includes information about the DB instances associated with the DB clusters identified by these ARNs.

    • ‘db-instance-id` - Accepts DB instance identifiers and DB instance Amazon Resource Names (ARNs). The results list only includes information about the DB instances identified by these ARNs.

    • ‘dbi-resource-id` - Accepts DB instance resource identifiers. The results list only includes information about the DB instances identified by these DB instance resource identifiers.

    • ‘domain` - Accepts Active Directory directory IDs. The results list only includes information about the DB instances associated with these domains.

    • ‘engine` - Accepts engine names. The results list only includes information about the DB instances for these engines.

Returns:



3223
3224
3225
3226
3227
3228
3229
3230
3231
3232
3233
3234
3235
3236
3237
3238
3239
3240
3241
# File 'lib/aws-sdk-rds/resource.rb', line 3223

def db_instances(options = {})
  batches = Enumerator.new do |y|
    resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
      @client.describe_db_instances(options)
    end
    resp.each_page do |page|
      batch = []
      page.data.db_instances.each do |d|
        batch << DBInstance.new(
          id: d.db_instance_identifier,
          data: d,
          client: @client
        )
      end
      y.yield(batch)
    end
  end
  DBInstance::Collection.new(batches)
end

#db_parameter_group(name) ⇒ DBParameterGroup

Parameters:

  • name (String)

Returns:



3245
3246
3247
3248
3249
3250
# File 'lib/aws-sdk-rds/resource.rb', line 3245

def db_parameter_group(name)
  DBParameterGroup.new(
    name: name,
    client: @client
  )
end

#db_parameter_group_family(name) ⇒ DBParameterGroupFamily

Parameters:

  • name (String)

Returns:



3254
3255
3256
3257
3258
3259
# File 'lib/aws-sdk-rds/resource.rb', line 3254

def db_parameter_group_family(name)
  DBParameterGroupFamily.new(
    name: name,
    client: @client
  )
end

#db_parameter_groups(options = {}) ⇒ DBParameterGroup::Collection

Examples:

Request syntax with placeholder values


db_parameter_groups = rds.db_parameter_groups({
  db_parameter_group_name: "String",
  filters: [
    {
      name: "String", # required
      values: ["String"], # required
    },
  ],
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :db_parameter_group_name (String)

    The name of a specific DB parameter group to return details for.

    Constraints:

    • If supplied, must match the name of an existing DBClusterParameterGroup.

    ^

  • :filters (Array<Types::Filter>)

    This parameter isn’t currently supported.

Returns:



3285
3286
3287
3288
3289
3290
3291
3292
3293
3294
3295
3296
3297
3298
3299
3300
3301
3302
3303
# File 'lib/aws-sdk-rds/resource.rb', line 3285

def db_parameter_groups(options = {})
  batches = Enumerator.new do |y|
    resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
      @client.describe_db_parameter_groups(options)
    end
    resp.each_page do |page|
      batch = []
      page.data.db_parameter_groups.each do |d|
        batch << DBParameterGroup.new(
          name: d.db_parameter_group_name,
          data: d,
          client: @client
        )
      end
      y.yield(batch)
    end
  end
  DBParameterGroup::Collection.new(batches)
end

#db_security_group(name) ⇒ DBSecurityGroup

Parameters:

  • name (String)

Returns:



3307
3308
3309
3310
3311
3312
# File 'lib/aws-sdk-rds/resource.rb', line 3307

def db_security_group(name)
  DBSecurityGroup.new(
    name: name,
    client: @client
  )
end

#db_security_groups(options = {}) ⇒ DBSecurityGroup::Collection

Examples:

Request syntax with placeholder values


db_security_groups = rds.db_security_groups({
  db_security_group_name: "String",
  filters: [
    {
      name: "String", # required
      values: ["String"], # required
    },
  ],
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :db_security_group_name (String)

    The name of the DB security group to return details for.

  • :filters (Array<Types::Filter>)

    This parameter isn’t currently supported.

Returns:



3331
3332
3333
3334
3335
3336
3337
3338
3339
3340
3341
3342
3343
3344
3345
3346
3347
3348
3349
# File 'lib/aws-sdk-rds/resource.rb', line 3331

def db_security_groups(options = {})
  batches = Enumerator.new do |y|
    resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
      @client.describe_db_security_groups(options)
    end
    resp.each_page do |page|
      batch = []
      page.data.db_security_groups.each do |d|
        batch << DBSecurityGroup.new(
          name: d.db_security_group_name,
          data: d,
          client: @client
        )
      end
      y.yield(batch)
    end
  end
  DBSecurityGroup::Collection.new(batches)
end

#db_snapshots(options = {}) ⇒ DBSnapshot::Collection

Examples:

Request syntax with placeholder values


db_snapshots = rds.db_snapshots({
  db_instance_identifier: "String",
  db_snapshot_identifier: "String",
  snapshot_type: "String",
  filters: [
    {
      name: "String", # required
      values: ["String"], # required
    },
  ],
  include_shared: false,
  include_public: false,
  dbi_resource_id: "String",
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :db_instance_identifier (String)

    The ID of the DB instance to retrieve the list of DB snapshots for. This parameter isn’t case-sensitive.

    Constraints:

    • If supplied, must match the identifier of an existing DBInstance.

    ^

  • :db_snapshot_identifier (String)

    A specific DB snapshot identifier to describe. This value is stored as a lowercase string.

    Constraints:

    • If supplied, must match the identifier of an existing DBSnapshot.

    • If this identifier is for an automated snapshot, the ‘SnapshotType` parameter must also be specified.

  • :snapshot_type (String)

    The type of snapshots to be returned. You can specify one of the following values:

    • ‘automated` - Return all DB snapshots that have been automatically taken by Amazon RDS for my Amazon Web Services account.

    • ‘manual` - Return all DB snapshots that have been taken by my Amazon Web Services account.

    • ‘shared` - Return all manual DB snapshots that have been shared to my Amazon Web Services account.

    • ‘public` - Return all DB snapshots that have been marked as public.

    • ‘awsbackup` - Return the DB snapshots managed by the Amazon Web Services Backup service.

      For information about Amazon Web Services Backup, see the [ *Amazon Web Services Backup Developer Guide.* ][1]

      The ‘awsbackup` type does not apply to Aurora.

    If you don’t specify a ‘SnapshotType` value, then both automated and manual snapshots are returned. Shared and public DB snapshots are not included in the returned results by default. You can include shared snapshots with these results by enabling the `IncludeShared` parameter. You can include public snapshots with these results by enabling the `IncludePublic` parameter.

    The ‘IncludeShared` and `IncludePublic` parameters don’t apply for ‘SnapshotType` values of `manual` or `automated`. The `IncludePublic` parameter doesn’t apply when ‘SnapshotType` is set to `shared`. The `IncludeShared` parameter doesn’t apply when ‘SnapshotType` is set to `public`.

    [1]: docs.aws.amazon.com/aws-backup/latest/devguide/whatisbackup.html

  • :filters (Array<Types::Filter>)

    A filter that specifies one or more DB snapshots to describe.

    Supported filters:

    • ‘db-instance-id` - Accepts DB instance identifiers and DB instance Amazon Resource Names (ARNs).

    • ‘db-snapshot-id` - Accepts DB snapshot identifiers.

    • ‘dbi-resource-id` - Accepts identifiers of source DB instances.

    • ‘snapshot-type` - Accepts types of DB snapshots.

    • ‘engine` - Accepts names of database engines.

  • :include_shared (Boolean)

    Specifies whether to include shared manual DB cluster snapshots from other Amazon Web Services accounts that this Amazon Web Services account has been given permission to copy or restore. By default, these snapshots are not included.

    You can give an Amazon Web Services account permission to restore a manual DB snapshot from another Amazon Web Services account by using the ‘ModifyDBSnapshotAttribute` API action.

    This setting doesn’t apply to RDS Custom.

  • :include_public (Boolean)

    Specifies whether to include manual DB cluster snapshots that are public and can be copied or restored by any Amazon Web Services account. By default, the public snapshots are not included.

    You can share a manual DB snapshot as public by using the ModifyDBSnapshotAttribute API.

    This setting doesn’t apply to RDS Custom.

  • :dbi_resource_id (String)

    A specific DB resource ID to describe.

Returns:



3464
3465
3466
3467
3468
3469
3470
3471
3472
3473
3474
3475
3476
3477
3478
3479
3480
3481
3482
3483
# File 'lib/aws-sdk-rds/resource.rb', line 3464

def db_snapshots(options = {})
  batches = Enumerator.new do |y|
    resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
      @client.describe_db_snapshots(options)
    end
    resp.each_page do |page|
      batch = []
      page.data.db_snapshots.each do |d|
        batch << DBSnapshot.new(
          instance_id: d.db_instance_identifier,
          snapshot_id: d.db_snapshot_identifier,
          data: d,
          client: @client
        )
      end
      y.yield(batch)
    end
  end
  DBSnapshot::Collection.new(batches)
end

#db_subnet_group(name) ⇒ DBSubnetGroup

Parameters:

  • name (String)

Returns:



3487
3488
3489
3490
3491
3492
# File 'lib/aws-sdk-rds/resource.rb', line 3487

def db_subnet_group(name)
  DBSubnetGroup.new(
    name: name,
    client: @client
  )
end

#db_subnet_groups(options = {}) ⇒ DBSubnetGroup::Collection

Examples:

Request syntax with placeholder values


db_subnet_groups = rds.db_subnet_groups({
  db_subnet_group_name: "String",
  filters: [
    {
      name: "String", # required
      values: ["String"], # required
    },
  ],
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :db_subnet_group_name (String)

    The name of the DB subnet group to return details for.

  • :filters (Array<Types::Filter>)

    This parameter isn’t currently supported.

Returns:



3511
3512
3513
3514
3515
3516
3517
3518
3519
3520
3521
3522
3523
3524
3525
3526
3527
3528
3529
# File 'lib/aws-sdk-rds/resource.rb', line 3511

def db_subnet_groups(options = {})
  batches = Enumerator.new do |y|
    resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
      @client.describe_db_subnet_groups(options)
    end
    resp.each_page do |page|
      batch = []
      page.data.db_subnet_groups.each do |d|
        batch << DBSubnetGroup.new(
          name: d.db_subnet_group_name,
          data: d,
          client: @client
        )
      end
      y.yield(batch)
    end
  end
  DBSubnetGroup::Collection.new(batches)
end

#event_category_map(source_type) ⇒ EventCategoryMap

Parameters:

  • source_type (String)

Returns:



3533
3534
3535
3536
3537
3538
# File 'lib/aws-sdk-rds/resource.rb', line 3533

def event_category_map(source_type)
  EventCategoryMap.new(
    source_type: source_type,
    client: @client
  )
end

#event_category_maps(options = {}) ⇒ EventCategoryMap::Collection

Examples:

Request syntax with placeholder values


event_category_maps = rds.event_category_maps({
  source_type: "String",
  filters: [
    {
      name: "String", # required
      values: ["String"], # required
    },
  ],
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :source_type (String)

    The type of source that is generating the events. For RDS Proxy events, specify ‘db-proxy`.

    Valid Values: ‘db-instance` | `db-cluster` | `db-parameter-group` | `db-security-group` | `db-snapshot` | `db-cluster-snapshot` | `db-proxy`

  • :filters (Array<Types::Filter>)

    This parameter isn’t currently supported.

Returns:



3562
3563
3564
3565
3566
3567
3568
3569
3570
3571
3572
3573
3574
3575
3576
3577
3578
# File 'lib/aws-sdk-rds/resource.rb', line 3562

def event_category_maps(options = {})
  batches = Enumerator.new do |y|
    batch = []
    resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
      @client.describe_event_categories(options)
    end
    resp.data.event_categories_map_list.each do |e|
      batch << EventCategoryMap.new(
        source_type: e.source_type,
        data: e,
        client: @client
      )
    end
    y.yield(batch)
  end
  EventCategoryMap::Collection.new(batches)
end

#event_subscription(name) ⇒ EventSubscription

Parameters:

  • name (String)

Returns:



3582
3583
3584
3585
3586
3587
# File 'lib/aws-sdk-rds/resource.rb', line 3582

def event_subscription(name)
  EventSubscription.new(
    name: name,
    client: @client
  )
end

#event_subscriptions(options = {}) ⇒ EventSubscription::Collection

Examples:

Request syntax with placeholder values


event_subscriptions = rds.event_subscriptions({
  subscription_name: "String",
  filters: [
    {
      name: "String", # required
      values: ["String"], # required
    },
  ],
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :subscription_name (String)

    The name of the RDS event notification subscription you want to describe.

  • :filters (Array<Types::Filter>)

    This parameter isn’t currently supported.

Returns:



3607
3608
3609
3610
3611
3612
3613
3614
3615
3616
3617
3618
3619
3620
3621
3622
3623
3624
3625
# File 'lib/aws-sdk-rds/resource.rb', line 3607

def event_subscriptions(options = {})
  batches = Enumerator.new do |y|
    resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
      @client.describe_event_subscriptions(options)
    end
    resp.each_page do |page|
      batch = []
      page.data.event_subscriptions_list.each do |e|
        batch << EventSubscription.new(
          name: e.cust_subscription_id,
          data: e,
          client: @client
        )
      end
      y.yield(batch)
    end
  end
  EventSubscription::Collection.new(batches)
end

#events(options = {}) ⇒ Event::Collection

Examples:

Request syntax with placeholder values


events = rds.events({
  source_identifier: "String",
  source_type: "db-instance", # accepts db-instance, db-parameter-group, db-security-group, db-snapshot, db-cluster, db-cluster-snapshot, custom-engine-version, db-proxy, blue-green-deployment
  start_time: Time.now,
  end_time: Time.now,
  duration: 1,
  event_categories: ["String"],
  filters: [
    {
      name: "String", # required
      values: ["String"], # required
    },
  ],
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :source_identifier (String)

    The identifier of the event source for which events are returned. If not specified, then all sources are included in the response.

    Constraints:

    • If ‘SourceIdentifier` is supplied, `SourceType` must also be provided.

    • If the source type is a DB instance, a ‘DBInstanceIdentifier` value must be supplied.

    • If the source type is a DB cluster, a ‘DBClusterIdentifier` value must be supplied.

    • If the source type is a DB parameter group, a ‘DBParameterGroupName` value must be supplied.

    • If the source type is a DB security group, a ‘DBSecurityGroupName` value must be supplied.

    • If the source type is a DB snapshot, a ‘DBSnapshotIdentifier` value must be supplied.

    • If the source type is a DB cluster snapshot, a ‘DBClusterSnapshotIdentifier` value must be supplied.

    • If the source type is an RDS Proxy, a ‘DBProxyName` value must be supplied.

    • Can’t end with a hyphen or contain two consecutive hyphens.

  • :source_type (String)

    The event source to retrieve events for. If no value is specified, all events are returned.

  • :start_time (Time, DateTime, Date, Integer, String)

    The beginning of the time interval to retrieve events for, specified in ISO 8601 format. For more information about ISO 8601, go to the

    ISO8601 Wikipedia page.][1

    Example: 2009-07-08T18:00Z

    [1]: en.wikipedia.org/wiki/ISO_8601

  • :end_time (Time, DateTime, Date, Integer, String)

    The end of the time interval for which to retrieve events, specified in ISO 8601 format. For more information about ISO 8601, go to the

    ISO8601 Wikipedia page.][1

    Example: 2009-07-08T18:00Z

    [1]: en.wikipedia.org/wiki/ISO_8601

  • :duration (Integer)

    The number of minutes to retrieve events for.

    Default: 60

  • :event_categories (Array<String>)

    A list of event categories that trigger notifications for a event notification subscription.

  • :filters (Array<Types::Filter>)

    This parameter isn’t currently supported.

Returns:



3708
3709
3710
3711
3712
3713
3714
3715
3716
3717
3718
3719
3720
3721
3722
3723
3724
3725
3726
3727
# File 'lib/aws-sdk-rds/resource.rb', line 3708

def events(options = {})
  batches = Enumerator.new do |y|
    resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
      @client.describe_events(options)
    end
    resp.each_page do |page|
      batch = []
      page.data.events.each do |e|
        batch << Event.new(
          source_id: e.source_identifier,
          date: e.date,
          data: e,
          client: @client
        )
      end
      y.yield(batch)
    end
  end
  Event::Collection.new(batches)
end

#option_group(name) ⇒ OptionGroup

Parameters:

  • name (String)

Returns:



3731
3732
3733
3734
3735
3736
# File 'lib/aws-sdk-rds/resource.rb', line 3731

def option_group(name)
  OptionGroup.new(
    name: name,
    client: @client
  )
end

#option_groups(options = {}) ⇒ OptionGroup::Collection

Examples:

Request syntax with placeholder values


option_groups = rds.option_groups({
  option_group_name: "String",
  filters: [
    {
      name: "String", # required
      values: ["String"], # required
    },
  ],
  engine_name: "String",
  major_engine_version: "String",
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :option_group_name (String)

    The name of the option group to describe. Can’t be supplied together with EngineName or MajorEngineVersion.

  • :filters (Array<Types::Filter>)

    This parameter isn’t currently supported.

  • :engine_name (String)

    A filter to only include option groups associated with this database engine.

    Valid Values:

    • ‘db2-ae`

    • ‘db2-se`

    • ‘mariadb`

    • ‘mysql`

    • ‘oracle-ee`

    • ‘oracle-ee-cdb`

    • ‘oracle-se2`

    • ‘oracle-se2-cdb`

    • ‘postgres`

    • ‘sqlserver-ee`

    • ‘sqlserver-se`

    • ‘sqlserver-ex`

    • ‘sqlserver-web`

  • :major_engine_version (String)

    Filters the list of option groups to only include groups associated with a specific database engine version. If specified, then EngineName must also be specified.

Returns:



3793
3794
3795
3796
3797
3798
3799
3800
3801
3802
3803
3804
3805
3806
3807
3808
3809
3810
3811
# File 'lib/aws-sdk-rds/resource.rb', line 3793

def option_groups(options = {})
  batches = Enumerator.new do |y|
    resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
      @client.describe_option_groups(options)
    end
    resp.each_page do |page|
      batch = []
      page.data.option_groups_list.each do |o|
        batch << OptionGroup.new(
          name: o.option_group_name,
          data: o,
          client: @client
        )
      end
      y.yield(batch)
    end
  end
  OptionGroup::Collection.new(batches)
end

#pending_maintenance_action(target_arn, name) ⇒ PendingMaintenanceAction

Parameters:

  • target_arn (String)
  • name (String)

Returns:



3816
3817
3818
3819
3820
3821
3822
# File 'lib/aws-sdk-rds/resource.rb', line 3816

def pending_maintenance_action(target_arn, name)
  PendingMaintenanceAction.new(
    target_arn: target_arn,
    name: name,
    client: @client
  )
end

#reserved_db_instance(id) ⇒ ReservedDBInstance

Parameters:

  • id (String)

Returns:



3826
3827
3828
3829
3830
3831
# File 'lib/aws-sdk-rds/resource.rb', line 3826

def reserved_db_instance(id)
  ReservedDBInstance.new(
    id: id,
    client: @client
  )
end

#reserved_db_instances(options = {}) ⇒ ReservedDBInstance::Collection

Examples:

Request syntax with placeholder values


reserved_db_instances = rds.reserved_db_instances({
  reserved_db_instance_id: "String",
  reserved_db_instances_offering_id: "String",
  db_instance_class: "String",
  duration: "String",
  product_description: "String",
  offering_type: "String",
  multi_az: false,
  lease_id: "String",
  filters: [
    {
      name: "String", # required
      values: ["String"], # required
    },
  ],
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :reserved_db_instance_id (String)

    The reserved DB instance identifier filter value. Specify this parameter to show only the reservation that matches the specified reservation ID.

  • :reserved_db_instances_offering_id (String)

    The offering identifier filter value. Specify this parameter to show only purchased reservations matching the specified offering identifier.

  • :db_instance_class (String)

    The DB instance class filter value. Specify this parameter to show only those reservations matching the specified DB instances class.

  • :duration (String)

    The duration filter value, specified in years or seconds. Specify this parameter to show only reservations for this duration.

    Valid Values: ‘1 | 3 | 31536000 | 94608000`

  • :product_description (String)

    The product description filter value. Specify this parameter to show only those reservations matching the specified product description.

  • :offering_type (String)

    The offering type filter value. Specify this parameter to show only the available offerings matching the specified offering type.

    Valid Values: ‘“Partial Upfront” | “All Upfront” | “No Upfront” `

  • :multi_az (Boolean)

    Specifies whether to show only those reservations that support Multi-AZ.

  • :lease_id (String)

    The lease identifier filter value. Specify this parameter to show only the reservation that matches the specified lease ID.

    <note markdown=“1”> Amazon Web Services Support might request the lease ID for an issue related to a reserved DB instance.

    </note>
    
  • :filters (Array<Types::Filter>)

    This parameter isn’t currently supported.

Returns:



3890
3891
3892
3893
3894
3895
3896
3897
3898
3899
3900
3901
3902
3903
3904
3905
3906
3907
3908
# File 'lib/aws-sdk-rds/resource.rb', line 3890

def reserved_db_instances(options = {})
  batches = Enumerator.new do |y|
    resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
      @client.describe_reserved_db_instances(options)
    end
    resp.each_page do |page|
      batch = []
      page.data.reserved_db_instances.each do |r|
        batch << ReservedDBInstance.new(
          id: r.reserved_db_instance_id,
          data: r,
          client: @client
        )
      end
      y.yield(batch)
    end
  end
  ReservedDBInstance::Collection.new(batches)
end

#reserved_db_instances_offering(id) ⇒ ReservedDBInstancesOffering

Parameters:

  • id (String)

Returns:



3912
3913
3914
3915
3916
3917
# File 'lib/aws-sdk-rds/resource.rb', line 3912

def reserved_db_instances_offering(id)
  ReservedDBInstancesOffering.new(
    id: id,
    client: @client
  )
end

#reserved_db_instances_offerings(options = {}) ⇒ ReservedDBInstancesOffering::Collection

Examples:

Request syntax with placeholder values


reserved_db_instances_offerings = rds.reserved_db_instances_offerings({
  reserved_db_instances_offering_id: "String",
  db_instance_class: "String",
  duration: "String",
  product_description: "String",
  offering_type: "String",
  multi_az: false,
  filters: [
    {
      name: "String", # required
      values: ["String"], # required
    },
  ],
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :reserved_db_instances_offering_id (String)

    The offering identifier filter value. Specify this parameter to show only the available offering that matches the specified reservation identifier.

    Example: ‘438012d3-4052-4cc7-b2e3-8d3372e0e706`

  • :db_instance_class (String)

    The DB instance class filter value. Specify this parameter to show only the available offerings matching the specified DB instance class.

  • :duration (String)

    Duration filter value, specified in years or seconds. Specify this parameter to show only reservations for this duration.

    Valid Values: ‘1 | 3 | 31536000 | 94608000`

  • :product_description (String)

    Product description filter value. Specify this parameter to show only the available offerings that contain the specified product description.

    <note markdown=“1”> The results show offerings that partially match the filter value.

    </note>
    
  • :offering_type (String)

    The offering type filter value. Specify this parameter to show only the available offerings matching the specified offering type.

    Valid Values: ‘“Partial Upfront” | “All Upfront” | “No Upfront” `

  • :multi_az (Boolean)

    Specifies whether to show only those reservations that support Multi-AZ.

  • :filters (Array<Types::Filter>)

    This parameter isn’t currently supported.

Returns:



3969
3970
3971
3972
3973
3974
3975
3976
3977
3978
3979
3980
3981
3982
3983
3984
3985
3986
3987
# File 'lib/aws-sdk-rds/resource.rb', line 3969

def reserved_db_instances_offerings(options = {})
  batches = Enumerator.new do |y|
    resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
      @client.describe_reserved_db_instances_offerings(options)
    end
    resp.each_page do |page|
      batch = []
      page.data.reserved_db_instances_offerings.each do |r|
        batch << ReservedDBInstancesOffering.new(
          id: r.reserved_db_instances_offering_id,
          data: r,
          client: @client
        )
      end
      y.yield(batch)
    end
  end
  ReservedDBInstancesOffering::Collection.new(batches)
end

#resource_with_pending_maintenance_actions(arn) ⇒ ResourcePendingMaintenanceActionList

Parameters:

  • arn (String)

Returns:



3991
3992
3993
3994
3995
3996
# File 'lib/aws-sdk-rds/resource.rb', line 3991

def resource_with_pending_maintenance_actions(arn)
  ResourcePendingMaintenanceActionList.new(
    arn: arn,
    client: @client
  )
end

#resources_with_pending_maintenance_actions(options = {}) ⇒ ResourcePendingMaintenanceActionList::Collection

Examples:

Request syntax with placeholder values


resources_with_pending_maintenance_actions = rds.resources_with_pending_maintenance_actions({
  resource_identifier: "String",
  filters: [
    {
      name: "String", # required
      values: ["String"], # required
    },
  ],
})

Parameters:

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :resource_identifier (String)

    The ARN of a resource to return pending maintenance actions for.

  • :filters (Array<Types::Filter>)

    A filter that specifies one or more resources to return pending maintenance actions for.

    Supported filters:

    • ‘db-cluster-id` - Accepts DB cluster identifiers and DB cluster Amazon Resource Names (ARNs). The results list only includes pending maintenance actions for the DB clusters identified by these ARNs.

    • ‘db-instance-id` - Accepts DB instance identifiers and DB instance ARNs. The results list only includes pending maintenance actions for the DB instances identified by these ARNs.

Returns:



4026
4027
4028
4029
4030
4031
4032
4033
4034
4035
4036
4037
4038
4039
4040
4041
4042
4043
4044
# File 'lib/aws-sdk-rds/resource.rb', line 4026

def resources_with_pending_maintenance_actions(options = {})
  batches = Enumerator.new do |y|
    resp = Aws::Plugins::UserAgent.metric('RESOURCE_MODEL') do
      @client.describe_pending_maintenance_actions(options)
    end
    resp.each_page do |page|
      batch = []
      page.data.pending_maintenance_actions.each do |p|
        batch << ResourcePendingMaintenanceActionList.new(
          arn: p.resource_identifier,
          data: p,
          client: @client
        )
      end
      y.yield(batch)
    end
  end
  ResourcePendingMaintenanceActionList::Collection.new(batches)
end