Skip to content

Commit

Permalink
Fix SQL instance sweeper to only delete sweepable instances (#7602) (#…
Browse files Browse the repository at this point in the history
…5418)

Signed-off-by: Modular Magician <[email protected]>
  • Loading branch information
modular-magician authored Apr 3, 2023
1 parent 6278f80 commit be9d2f6
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .changelog/7602.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:none

```
4 changes: 4 additions & 0 deletions google-beta/resource_sql_database_instance_sweeper_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,10 @@ func testSweepSQLDatabaseInstance(region string) error {
}

for _, d := range found.Items {
if !IsSweepableTestResource(d.Name) {
continue
}

// don't delete replicas, we'll take care of that
// when deleting the database they replicate
if d.ReplicaConfiguration != nil {
Expand Down

0 comments on commit be9d2f6

Please sign in to comment.