From f1a0c9fcb2c32997f11110c70e194db16f43f8a0 Mon Sep 17 00:00:00 2001 From: Valentin Shirshov Date: Fri, 3 Nov 2023 10:24:28 +0100 Subject: [PATCH] [DBInstance] Add support for the Dedicated Log Volume (#476) Co-authored-by: Valentin Shirshov --- aws-rds-cfn-common/pom.xml | 4 ++-- aws-rds-customdbengineversion/pom.xml | 2 +- aws-rds-dbcluster/pom.xml | 4 ++-- aws-rds-dbclusterendpoint/pom.xml | 2 +- aws-rds-dbclusterparametergroup/pom.xml | 2 +- aws-rds-dbinstance/aws-rds-dbinstance.json | 4 ++++ aws-rds-dbinstance/docs/README.md | 12 ++++++++++++ aws-rds-dbinstance/pom.xml | 4 ++-- .../software/amazon/rds/dbinstance/Translator.java | 6 ++++++ aws-rds-dbparametergroup/pom.xml | 2 +- aws-rds-dbsubnetgroup/pom.xml | 2 +- aws-rds-eventsubscription/pom.xml | 2 +- aws-rds-globalcluster/pom.xml | 2 +- aws-rds-optiongroup/pom.xml | 2 +- 14 files changed, 36 insertions(+), 14 deletions(-) diff --git a/aws-rds-cfn-common/pom.xml b/aws-rds-cfn-common/pom.xml index 4685108c0..788649bd5 100644 --- a/aws-rds-cfn-common/pom.xml +++ b/aws-rds-cfn-common/pom.xml @@ -27,12 +27,12 @@ software.amazon.awssdk utils - 2.20.98 + 2.21.6 software.amazon.awssdk rds - 2.20.98 + 2.21.6 software.amazon.cloudformation diff --git a/aws-rds-customdbengineversion/pom.xml b/aws-rds-customdbengineversion/pom.xml index d2c38117e..719913d8b 100644 --- a/aws-rds-customdbengineversion/pom.xml +++ b/aws-rds-customdbengineversion/pom.xml @@ -22,7 +22,7 @@ software.amazon.awssdk rds - 2.20.98 + 2.21.6 software.amazon.rds.common diff --git a/aws-rds-dbcluster/pom.xml b/aws-rds-dbcluster/pom.xml index da17b2898..a10d15ab8 100644 --- a/aws-rds-dbcluster/pom.xml +++ b/aws-rds-dbcluster/pom.xml @@ -29,12 +29,12 @@ software.amazon.awssdk rds - 2.20.98 + 2.21.6 software.amazon.awssdk ec2 - 2.20.98 + 2.21.6 diff --git a/aws-rds-dbclusterendpoint/pom.xml b/aws-rds-dbclusterendpoint/pom.xml index 98f8101a4..7625b8cfa 100644 --- a/aws-rds-dbclusterendpoint/pom.xml +++ b/aws-rds-dbclusterendpoint/pom.xml @@ -29,7 +29,7 @@ software.amazon.awssdk rds - 2.20.98 + 2.21.6 diff --git a/aws-rds-dbclusterparametergroup/pom.xml b/aws-rds-dbclusterparametergroup/pom.xml index 089897241..ef621b670 100644 --- a/aws-rds-dbclusterparametergroup/pom.xml +++ b/aws-rds-dbclusterparametergroup/pom.xml @@ -29,7 +29,7 @@ software.amazon.awssdk rds - 2.20.98 + 2.21.6 diff --git a/aws-rds-dbinstance/aws-rds-dbinstance.json b/aws-rds-dbinstance/aws-rds-dbinstance.json index 91daa93f6..cf0abe04b 100644 --- a/aws-rds-dbinstance/aws-rds-dbinstance.json +++ b/aws-rds-dbinstance/aws-rds-dbinstance.json @@ -224,6 +224,10 @@ "type": "string", "description": "The Oracle system ID (Oracle SID) for a container database (CDB). The Oracle SID is also the name of the CDB. This setting is valid for RDS Custom only." }, + "DedicatedLogVolume": { + "type": "boolean", + "description": "Indicates whether the DB instance has a dedicated log volume (DLV) enabled." + }, "DeleteAutomatedBackups": { "type": "boolean", "description": "A value that indicates whether to remove automated backups immediately after the DB instance is deleted. This parameter isn't case-sensitive. The default is to remove automated backups immediately after the DB instance is deleted." diff --git a/aws-rds-dbinstance/docs/README.md b/aws-rds-dbinstance/docs/README.md index b6c71d7bf..119a35885 100644 --- a/aws-rds-dbinstance/docs/README.md +++ b/aws-rds-dbinstance/docs/README.md @@ -34,6 +34,7 @@ To declare this entity in your AWS CloudFormation template, use the following sy "DBSecurityGroups" : [ String, ... ], "DBSnapshotIdentifier" : String, "DBSubnetGroupName" : String, + "DedicatedLogVolume" : Boolean, "DeleteAutomatedBackups" : Boolean, "DeletionProtection" : Boolean, "Domain" : String, @@ -120,6 +121,7 @@ Properties: - String DBSnapshotIdentifier: String DBSubnetGroupName: String + DedicatedLogVolume: Boolean DeleteAutomatedBackups: Boolean DeletionProtection: Boolean Domain: String @@ -427,6 +429,16 @@ _Type_: String _Update requires_: [Replacement](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-replacement) +#### DedicatedLogVolume + +Indicates whether the DB instance has a dedicated log volume (DLV) enabled. + +_Required_: No + +_Type_: Boolean + +_Update requires_: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt) + #### DeleteAutomatedBackups A value that indicates whether to remove automated backups immediately after the DB instance is deleted. This parameter isn't case-sensitive. The default is to remove automated backups immediately after the DB instance is deleted. diff --git a/aws-rds-dbinstance/pom.xml b/aws-rds-dbinstance/pom.xml index 0c272511b..a8784cff0 100644 --- a/aws-rds-dbinstance/pom.xml +++ b/aws-rds-dbinstance/pom.xml @@ -32,12 +32,12 @@ software.amazon.awssdk rds - 2.20.98 + 2.21.6 software.amazon.awssdk ec2 - 2.20.98 + 2.21.6 diff --git a/aws-rds-dbinstance/src/main/java/software/amazon/rds/dbinstance/Translator.java b/aws-rds-dbinstance/src/main/java/software/amazon/rds/dbinstance/Translator.java index bd94c0462..945e60344 100644 --- a/aws-rds-dbinstance/src/main/java/software/amazon/rds/dbinstance/Translator.java +++ b/aws-rds-dbinstance/src/main/java/software/amazon/rds/dbinstance/Translator.java @@ -120,6 +120,7 @@ public static CreateDbInstanceReadReplicaRequest createDbInstanceReadReplicaRequ .dbInstanceIdentifier(model.getDBInstanceIdentifier()) .dbSubnetGroupName(model.getDBSubnetGroupName()) .deletionProtection(model.getDeletionProtection()) + .dedicatedLogVolume(model.getDedicatedLogVolume()) .domain(model.getDomain()) .domainAuthSecretArn(model.getDomainAuthSecretArn()) .domainDnsIps(model.getDomainDnsIps()) @@ -200,6 +201,7 @@ public static RestoreDbInstanceFromDbSnapshotRequest restoreDbInstanceFromSnapsh .dbSnapshotIdentifier(model.getDBSnapshotIdentifier()) .dbSubnetGroupName(model.getDBSubnetGroupName()) .deletionProtection(model.getDeletionProtection()) + .dedicatedLogVolume(model.getDedicatedLogVolume()) .domain(model.getDomain()) .domainAuthSecretArn(model.getDomainAuthSecretArn()) .domainDnsIps(model.getDomainDnsIps()) @@ -282,6 +284,7 @@ public static CreateDbInstanceRequest createDbInstanceRequest( .dbName(model.getDBName()) .dbParameterGroupName(model.getDBParameterGroupName()) .dbSubnetGroupName(model.getDBSubnetGroupName()) + .dedicatedLogVolume(model.getDedicatedLogVolume()) .deletionProtection(model.getDeletionProtection()) .domain(model.getDomain()) .domainAuthSecretArn(model.getDomainAuthSecretArn()) @@ -349,6 +352,7 @@ static RestoreDbInstanceToPointInTimeRequest restoreDbInstanceToPointInTimeReque .dbName(model.getDBName()) .dbParameterGroupName(model.getDBParameterGroupName()) .dbSubnetGroupName(model.getDBSubnetGroupName()) + .dedicatedLogVolume(model.getDedicatedLogVolume()) .deletionProtection(model.getDeletionProtection()) .domain(model.getDomain()) .domainAuthSecretArn(model.getDomainAuthSecretArn()) @@ -440,6 +444,7 @@ public static ModifyDbInstanceRequest modifyDbInstanceRequest( .dbInstanceIdentifier(desiredModel.getDBInstanceIdentifier()) .dbParameterGroupName(diff(previousModel.getDBParameterGroupName(), desiredModel.getDBParameterGroupName())) .dbPortNumber(translatePortToSdk(diff(previousModel.getPort(), desiredModel.getPort()))) + .dedicatedLogVolume(diff(previousModel.getDeletionProtection(), desiredModel.getDeletionProtection())) .deletionProtection(diff(previousModel.getDeletionProtection(), desiredModel.getDeletionProtection())) .domain(diff(previousModel.getDomain(), desiredModel.getDomain())) .domainAuthSecretArn(desiredModel.getDomainAuthSecretArn()) @@ -817,6 +822,7 @@ public static ResourceModel.ResourceModelBuilder translateDbInstanceFromSdkBuild .dBSubnetGroupName(translateDbSubnetGroupFromSdk(dbInstance.dbSubnetGroup())) .dBSystemId(dbInstance.dbSystemId()) .dbiResourceId(dbInstance.dbiResourceId()) + .dedicatedLogVolume(dbInstance.dedicatedLogVolume()) .deletionProtection(dbInstance.deletionProtection()) .domain(domain) .domainAuthSecretArn(domainAuthSecretArn) diff --git a/aws-rds-dbparametergroup/pom.xml b/aws-rds-dbparametergroup/pom.xml index 06a626a33..ff3ddcdec 100644 --- a/aws-rds-dbparametergroup/pom.xml +++ b/aws-rds-dbparametergroup/pom.xml @@ -22,7 +22,7 @@ software.amazon.awssdk rds - 2.20.98 + 2.21.6 diff --git a/aws-rds-dbsubnetgroup/pom.xml b/aws-rds-dbsubnetgroup/pom.xml index f95414bf7..c14fc5f6b 100644 --- a/aws-rds-dbsubnetgroup/pom.xml +++ b/aws-rds-dbsubnetgroup/pom.xml @@ -22,7 +22,7 @@ software.amazon.awssdk rds - 2.20.98 + 2.21.6 diff --git a/aws-rds-eventsubscription/pom.xml b/aws-rds-eventsubscription/pom.xml index 6894e3823..5dee65b86 100644 --- a/aws-rds-eventsubscription/pom.xml +++ b/aws-rds-eventsubscription/pom.xml @@ -28,7 +28,7 @@ software.amazon.awssdk rds - 2.20.98 + 2.21.6 diff --git a/aws-rds-globalcluster/pom.xml b/aws-rds-globalcluster/pom.xml index 19460eae9..de106c684 100644 --- a/aws-rds-globalcluster/pom.xml +++ b/aws-rds-globalcluster/pom.xml @@ -28,7 +28,7 @@ software.amazon.awssdk rds - 2.20.98 + 2.21.6 diff --git a/aws-rds-optiongroup/pom.xml b/aws-rds-optiongroup/pom.xml index 01f440737..50f98a62f 100644 --- a/aws-rds-optiongroup/pom.xml +++ b/aws-rds-optiongroup/pom.xml @@ -22,7 +22,7 @@ software.amazon.awssdk rds - 2.20.98 + 2.21.6