feat: major inplace upgrade, deletion protection #665
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Add support for two ICD features:
Deletion protection
This is feature flag, that when set to true provides protection from accidentally deleting the ICD instance.
Conceptually the instance is created with this flag set to true and if/when a destroy is attempted the request fails. In addition to requesting a destroy the flag must be set to false.
Note: This does not prevent the resource being destroyed outside of terraform.
In place major version upgrade
This feature allows the major version, eg. 6.0 to upgraded to 7.0 by an in-place upgrade, retaining the original instance connection endpoints. During a major version upgrade, the instance is set to read-only (setUserWriteBlock mode), upgraded and set to accept writes again. There is a service outage during this time, since the service will not accept database updates.
There is an feature flag, version_upgrade_skip_backup. It is NOT recommended to use this feature, since an upgrade failure may result in data loss. This flag avoids taking a backup whilst in read-only mode to speed the process up.
Full documentation at: https://cloud.ibm.com/docs/databases-for-postgresql?topic=databases-for-postgresql-upgrading&interface=ui
Release required?
x.x.X)x.X.x)X.x.x)Release notes content
Run the pipeline
If the CI pipeline doesn't run when you create the PR, the PR requires a user with GitHub collaborators access to run the pipeline.
Run the CI pipeline when the PR is ready for review and you expect tests to pass. Add a comment to the PR with the following text:
Checklist for reviewers
For mergers