aws_sdk_rds/client/delete_db_instance.rs
1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2impl super::Client {
3 /// Constructs a fluent builder for the [`DeleteDBInstance`](crate::operation::delete_db_instance::builders::DeleteDBInstanceFluentBuilder) operation.
4 ///
5 /// - The fluent builder is configurable:
6 /// - [`db_instance_identifier(impl Into<String>)`](crate::operation::delete_db_instance::builders::DeleteDBInstanceFluentBuilder::db_instance_identifier) / [`set_db_instance_identifier(Option<String>)`](crate::operation::delete_db_instance::builders::DeleteDBInstanceFluentBuilder::set_db_instance_identifier):<br>required: **true**<br><p>The DB instance identifier for the DB instance to be deleted. This parameter isn't case-sensitive.</p> <p>Constraints:</p> <ul> <li> <p>Must match the name of an existing DB instance.</p></li> </ul><br>
7 /// - [`skip_final_snapshot(bool)`](crate::operation::delete_db_instance::builders::DeleteDBInstanceFluentBuilder::skip_final_snapshot) / [`set_skip_final_snapshot(Option<bool>)`](crate::operation::delete_db_instance::builders::DeleteDBInstanceFluentBuilder::set_skip_final_snapshot):<br>required: **false**<br><p>Specifies whether to skip the creation of a final DB snapshot before deleting the instance. If you enable this parameter, RDS doesn't create a DB snapshot. If you don't enable this parameter, RDS creates a DB snapshot before the DB instance is deleted. By default, skip isn't enabled, and the DB snapshot is created.</p><note> <p>If you don't enable this parameter, you must specify the <code>FinalDBSnapshotIdentifier</code> parameter.</p> </note> <p>When a DB instance is in a failure state and has a status of <code>failed</code>, <code>incompatible-restore</code>, or <code>incompatible-network</code>, RDS can delete the instance only if you enable this parameter.</p> <p>If you delete a read replica or an RDS Custom instance, you must enable this setting.</p> <p>This setting is required for RDS Custom.</p><br>
8 /// - [`final_db_snapshot_identifier(impl Into<String>)`](crate::operation::delete_db_instance::builders::DeleteDBInstanceFluentBuilder::final_db_snapshot_identifier) / [`set_final_db_snapshot_identifier(Option<String>)`](crate::operation::delete_db_instance::builders::DeleteDBInstanceFluentBuilder::set_final_db_snapshot_identifier):<br>required: **false**<br><p>The <code>DBSnapshotIdentifier</code> of the new <code>DBSnapshot</code> created when the <code>SkipFinalSnapshot</code> parameter is disabled.</p><note> <p>If you enable this parameter and also enable SkipFinalShapshot, the command results in an error.</p> </note> <p>This setting doesn't apply to RDS Custom.</p> <p>Constraints:</p> <ul> <li> <p>Must be 1 to 255 letters or numbers.</p></li> <li> <p>First character must be a letter.</p></li> <li> <p>Can't end with a hyphen or contain two consecutive hyphens.</p></li> <li> <p>Can't be specified when deleting a read replica.</p></li> </ul><br>
9 /// - [`delete_automated_backups(bool)`](crate::operation::delete_db_instance::builders::DeleteDBInstanceFluentBuilder::delete_automated_backups) / [`set_delete_automated_backups(Option<bool>)`](crate::operation::delete_db_instance::builders::DeleteDBInstanceFluentBuilder::set_delete_automated_backups):<br>required: **false**<br><p>Specifies 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.</p><br>
10 /// - On success, responds with [`DeleteDbInstanceOutput`](crate::operation::delete_db_instance::DeleteDbInstanceOutput) with field(s):
11 /// - [`db_instance(Option<DbInstance>)`](crate::operation::delete_db_instance::DeleteDbInstanceOutput::db_instance): <p>Contains the details of an Amazon RDS DB instance.</p> <p>This data type is used as a response element in the operations <code>CreateDBInstance</code>, <code>CreateDBInstanceReadReplica</code>, <code>DeleteDBInstance</code>, <code>DescribeDBInstances</code>, <code>ModifyDBInstance</code>, <code>PromoteReadReplica</code>, <code>RebootDBInstance</code>, <code>RestoreDBInstanceFromDBSnapshot</code>, <code>RestoreDBInstanceFromS3</code>, <code>RestoreDBInstanceToPointInTime</code>, <code>StartDBInstance</code>, and <code>StopDBInstance</code>.</p>
12 /// - On failure, responds with [`SdkError<DeleteDBInstanceError>`](crate::operation::delete_db_instance::DeleteDBInstanceError)
13 pub fn delete_db_instance(&self) -> crate::operation::delete_db_instance::builders::DeleteDBInstanceFluentBuilder {
14 crate::operation::delete_db_instance::builders::DeleteDBInstanceFluentBuilder::new(self.handle.clone())
15 }
16}