provider/aws: Log ElasticCache subnet removal

This commit is contained in:
clint shryock 2016-06-08 13:35:49 -05:00
parent 2a09941f76
commit 1624c7e27f
1 changed files with 1 additions and 0 deletions

View File

@ -89,6 +89,7 @@ func resourceAwsElasticacheSubnetGroupRead(d *schema.ResourceData, meta interfac
if err != nil {
if ec2err, ok := err.(awserr.Error); ok && ec2err.Code() == "CacheSubnetGroupNotFoundFault" {
// Update state to indicate the db subnet no longer exists.
log.Printf("[WARN] Elasticache Subnet Group (%s) not found, removing from state", d.Id())
d.SetId("")
return nil
}