Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[backport -> release/3.7.x] tests(ci): fix migration test failed to run when updating migration files for an unreleased version #13141

Merged
merged 1 commit into from
Jun 3, 2024

Conversation

team-gateway-bot
Copy link
Collaborator

Automated backport to release/3.7.x, triggered by a label in #13134.

Original description

Summary

This PR fixes an issue that migration tests will fail when the migration files for the next unreleased version get updated.

It has created a PR base branch next/3.4.x.x. Add migration scripts to the existing script file, such as kong/enterprise_edition/db/migrations/enterprise/021_3435_to_3436.lua. It will be ignored when executing kong migrations up.

case 1: upgrade next/2.8.x.x to the current PR of the next/3.4.x.x. the migration 021_3435_to_3436.lua is always new.
The upgrade_tests are work well.

case 2: Upgrade next/3.4.x.x to the current PR of next/3.4.x.x. When starting the next/3.4.x.x container, the migration script 021_3435_to_3436.lua will be bootstrapped for the first time. Then, upgrade to this PR. The second time using kong migrations up to bootstrap the script will not execute the migration script 021_3435_to_3436.lua.

There is an example. https://github.com/Kong/kong-ee/actions/runs/9310936847/job/25629308613

Checklist

  • The Pull Request has tests
  • A changelog file has been added to CHANGELOG/unreleased/kong or adding skip-changelog label on PR if unnecessary. README.md
  • The Pull Request has backports to all the versions it needs to cover
  • There is a user-facing docs PR against https://github.com/Kong/docs.konghq.com - PUT DOCS PR HERE

…iles for an unreleased version (#13134)

(cherry picked from commit 09523a4)
@windmgc windmgc merged commit 5d7a671 into release/3.7.x Jun 3, 2024
36 checks passed
@windmgc windmgc deleted the backport-13134-to-release/3.7.x branch June 3, 2024 07:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cherry-pick kong-ee schedule this PR for cherry-picking to kong/kong-ee size/XS
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants