Skip to content

sql: add include_replicas_for_major_version_upgrade to google_sql_database_instance#18172

Open
DrFaust92 wants to merge 1 commit into
GoogleCloudPlatform:mainfrom
DrFaust92:sql-include-replicas-major-version-upgrade
Open

sql: add include_replicas_for_major_version_upgrade to google_sql_database_instance#18172
DrFaust92 wants to merge 1 commit into
GoogleCloudPlatform:mainfrom
DrFaust92:sql-include-replicas-major-version-upgrade

Conversation

@DrFaust92

Copy link
Copy Markdown
Contributor

Adds the input-only include_replicas_for_major_version_upgrade field to google_sql_database_instance.

When set to true, an in-place major version upgrade of the primary instance (triggered by a database_version change) also upgrades its read replicas in place. The field is input-only in the Cloud SQL Admin API and is sent on the atomic database_version patch during update.

Test

Added TestAccSqlDatabaseInstance_includeReplicasForMajorVersionUpgrade, which creates a MySQL 8.0 primary + read replica on a private network, then upgrades the primary to 8.4 with the flag enabled (the replica ignores database_version drift so the server-side cascade isn't raced). Passing locally:

--- PASS: TestAccSqlDatabaseInstance_includeReplicasForMajorVersionUpgrade (1772.45s)
sql: added `include_replicas_for_major_version_upgrade` field to `google_sql_database_instance`

@modular-magician modular-magician added the awaiting-approval Pull requests that need reviewer's approval to run presubmit tests label Jul 4, 2026
@google-cla

google-cla Bot commented Jul 4, 2026

Copy link
Copy Markdown

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@github-actions github-actions Bot requested a review from SirGitsalot July 4, 2026 21:55
@github-actions

github-actions Bot commented Jul 4, 2026

Copy link
Copy Markdown

Googlers: For automatic test runs see go/terraform-auto-test-runs.

@SirGitsalot, a repository maintainer, has been assigned to review your changes. If you have not received review feedback within 2 business days, please leave a comment on this PR asking them to take a look.

You can help make sure that review is quick by doing a self-review and by running impacted tests locally.

@DrFaust92 DrFaust92 force-pushed the sql-include-replicas-major-version-upgrade branch from dc5ea4f to 81f3312 Compare July 4, 2026 21:57
…abase_instance

Adds the input-only `include_replicas_for_major_version_upgrade` field to
`google_sql_database_instance`. When set to true, an in-place major version
upgrade of the primary (via a `database_version` change) also upgrades its
read replicas in place. The field is passed on the atomic database_version
patch, matching the Cloud SQL Admin API's input-only semantics.
@DrFaust92 DrFaust92 force-pushed the sql-include-replicas-major-version-upgrade branch from 81f3312 to d4aafc4 Compare July 4, 2026 22:36
@github-actions

github-actions Bot commented Jul 9, 2026

Copy link
Copy Markdown

@SirGitsalot This PR has been waiting for review for 3 weekdays. Please take a look! Use the label disable-review-reminders to disable these notifications.

@github-actions

Copy link
Copy Markdown

@GoogleCloudPlatform/terraform-team @SirGitsalot This PR has been waiting for review for 1 week. Please take a look! Use the label disable-review-reminders to disable these notifications.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting-approval Pull requests that need reviewer's approval to run presubmit tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants