Smaws_Client_RDS.DeleteDBInstanceDeletes a previously provisioned DB instance. When you delete a DB instance, all automated backups for that instance are deleted and can't be recovered. However, manual DB snapshots of the DB instance aren't deleted.
If you request a final DB snapshot, the status of the Amazon RDS DB instance is deleting until the DB snapshot is created. This operation can't be canceled or reverted after it begins. To monitor the status of this operation, use DescribeDBInstance.
When a DB instance is in a failure state and has a status of failed, incompatible-restore, or incompatible-network, you can only delete it when you skip creation of the final snapshot with the SkipFinalSnapshot parameter.
If the specified DB instance is part of an Amazon Aurora DB cluster, you can't delete the DB instance if both of the following conditions are true:
To delete a DB instance in this case, first use the PromoteReadReplicaDBCluster operation to promote the DB cluster so that it's no longer a read replica. After the promotion completes, use the DeleteDBInstance operation to delete the final instance in the DB cluster.
For RDS Custom DB instances, deleting the DB instance permanently deletes the EC2 instance and the associated EBS volumes. Make sure that you don't terminate or delete these resources before you delete the DB instance. Otherwise, deleting the DB instance and creation of the final snapshot might fail.
val error_to_string :
[ Smaws_Lib.Protocols.AwsQuery.error
| `DBInstanceAutomatedBackupQuotaExceededFault of
Types.db_instance_automated_backup_quota_exceeded_fault
| `DBInstanceNotFoundFault of Types.db_instance_not_found_fault
| `DBSnapshotAlreadyExistsFault of Types.db_snapshot_already_exists_fault
| `InvalidDBClusterStateFault of Types.invalid_db_cluster_state_fault
| `InvalidDBInstanceStateFault of Types.invalid_db_instance_state_fault
| `KMSKeyNotAccessibleFault of Types.kms_key_not_accessible_fault
| `SnapshotQuotaExceededFault of Types.snapshot_quota_exceeded_fault ] ->
stringval request :
'http_type Smaws_Lib.Context.t ->
Types.delete_db_instance_message ->
(Types.delete_db_instance_result,
[> Smaws_Lib.Protocols.AwsQuery.error
| `DBInstanceAutomatedBackupQuotaExceededFault of
Types.db_instance_automated_backup_quota_exceeded_fault
| `DBInstanceNotFoundFault of Types.db_instance_not_found_fault
| `DBSnapshotAlreadyExistsFault of Types.db_snapshot_already_exists_fault
| `InvalidDBClusterStateFault of Types.invalid_db_cluster_state_fault
| `InvalidDBInstanceStateFault of Types.invalid_db_instance_state_fault
| `KMSKeyNotAccessibleFault of Types.kms_key_not_accessible_fault
| `SnapshotQuotaExceededFault of Types.snapshot_quota_exceeded_fault ])
Stdlib.resultval request_with_metadata :
'http_type Smaws_Lib.Context.t ->
Types.delete_db_instance_message ->
(Types.delete_db_instance_result Smaws_Lib.Response.t,
[> Smaws_Lib.Protocols.AwsQuery.error
| `DBInstanceAutomatedBackupQuotaExceededFault of
Types.db_instance_automated_backup_quota_exceeded_fault
| `DBInstanceNotFoundFault of Types.db_instance_not_found_fault
| `DBSnapshotAlreadyExistsFault of Types.db_snapshot_already_exists_fault
| `InvalidDBClusterStateFault of Types.invalid_db_cluster_state_fault
| `InvalidDBInstanceStateFault of Types.invalid_db_instance_state_fault
| `KMSKeyNotAccessibleFault of Types.kms_key_not_accessible_fault
| `SnapshotQuotaExceededFault of Types.snapshot_quota_exceeded_fault ]
* Smaws_Lib.Response.metadata)
Stdlib.result