mirror of
https://github.com/opentofu/opentofu.git
synced 2025-02-25 18:45:20 -06:00
provider/aws: Refreshing the state when DBParameterGroupNotFound
happens
This commit is contained in:
parent
fdf1962905
commit
21a65fd085
@ -111,6 +111,12 @@ func resourceAwsRDSClusterParameterGroupRead(d *schema.ResourceData, meta interf
|
||||
|
||||
describeResp, err := rdsconn.DescribeDBClusterParameterGroups(&describeOpts)
|
||||
if err != nil {
|
||||
if awsErr, ok := err.(awserr.Error); ok && awsErr.Code() == "DBParameterGroupNotFound" {
|
||||
log.Printf("[WARN] DB Cluster Parameter Group (%s) not found, error code (404)", d.Id())
|
||||
d.SetId("")
|
||||
return nil
|
||||
}
|
||||
|
||||
return err
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user