terraform-google-modules / terraform-google-sql-db

Creates a Cloud SQL database instance
https://registry.terraform.io/modules/terraform-google-modules/sql-db/google
Apache License 2.0
265 stars 427 forks source link

fix(backup): backups are not deleted when retained nr of backups >= 20 #566

Closed tjespers closed 8 months ago

tjespers commented 9 months ago

fix(backup): backups are not deleted when retained nr of backups >= 20

This commit introduces a new module variable: backup_runs_list_max_results this variable is used to control the maximum amount of results that are returned by the googleapis.sqladmin.v1.backupRuns.list API call. By defaul this call only returns 20 results leading to a situation where no old backups will be deleted whenever the desired amount of retained backups exceed this number.

Fixes: #519

tjespers commented 8 months ago

@imrannayer @isaurabhuttam friendly pinging to see if there is anything i can do to help get this PR merged in?

g-awmalik commented 8 months ago

/gcbrun