Skip to content

Conversation

@shemau
Copy link
Contributor

@shemau shemau commented Nov 4, 2024

Description

Add a work around to remove the group block when restoring from a backup.

Release required?

  • No release
  • Patch release (x.x.X)
  • Minor release (x.X.x)
  • Major release (X.x.x)
Release notes content

Avoid defining the host_flavor during restore operations.

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:

/run pipeline

Checklist for reviewers

  • If relevant, a test for the change is included or updated with this PR.
  • If relevant, documentation for the change is included or updated with this PR.

For mergers

  • Use a conventional commit message to set the release level. Follow the guidelines.
  • Include information that users need to know about the PR in the commit message. The commit message becomes part of the GitHub release notes.
  • Use the Squash and merge option.

@shemau
Copy link
Contributor Author

shemau commented Nov 4, 2024

/run pipeline

## This block is for if host_flavor IS set to specific pre-defined host sizes and not set to "multitenant"
dynamic "group" {
for_each = local.host_flavor_set && var.member_host_flavor != "multitenant" ? [1] : []
for_each = local.host_flavor_set && var.member_host_flavor != "multitenant" && var.backup_crn == null ? [1] : []

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems this may prevent scaling after restoring from a backup?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The restore from backup is a one time operation.

In order to scale after restoring from backup, the process should (must) pass null in the backup_crn. This would restore the group block (per previous behaviour).

@shemau
Copy link
Contributor Author

shemau commented Nov 4, 2024

make run-tests-local RUN=TestRunRestoredDBExample

was run locally and passed. This was done to cover the backup/restore test which does not run as part of the PR validation.

Copy link
Contributor

@ocofaigh ocofaigh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As per ICD team, we need to update the timeout value for update. They suggest this:

timeouts {
    create = "120m"
    update = "120m"
    delete = "15m"
  }

@shemau
Copy link
Contributor Author

shemau commented Nov 5, 2024

/run pipeline

@shemau
Copy link
Contributor Author

shemau commented Nov 5, 2024

/run pipeline

@ocofaigh ocofaigh merged commit 21c0b23 into main Nov 5, 2024
1 of 2 checks passed
@ocofaigh ocofaigh deleted the restore-workaround branch November 5, 2024 16:45
@terraform-ibm-modules-ops
Copy link
Contributor

🎉 This PR is included in version 3.17.10 🎉

The release is available on:

Your semantic-release bot 📦🚀

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants