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
liquibase 4.25.0 works differently for migration and first time execution #5844
Comments
Hi @kirangodishala, I've tested the scenarios you've presented, but I'm not getting the same behaviour in all of them. I can confirm that running directly with 4.25.0 the files in your 1.32 version, the execution breaks with We'd appreciate it if you could propose a fix for this bug, though it will remain open for the community to fix if not. However, when I follow the steps of I don't get any checksum errors - the checksums are automatically upgraded to version 9. The same thing happens with 4.27.0. Could you provide the error message and/or the stack trace? |
Hi @kirangodishala @tati-qalified My case:
During my testing i found out that:
Based on these i selected the following approach:
This allowed me to prepare for the liquibase upgrade while i kept using the current version 4.5, and then upgrade to the latest - avoiding the need to coordinate all the changed to happen at the same time, and having a solution for both upgrades and new installs. Since using the |
@yevgenykuz - thanks a lot for the hack. I will try this approach. |
Search first
Description
We have been using liquibase 3.10.3 and we tried to migrate to 4.13.0 but it introduced
addAfterColumn is not allowed on postgresql
issue. We worked with you to fix this issue and rased this PR- #3978.And this was included in liquibase 4.23.2. But for this fix to work, we needed to include the below yaml snippet in our changelog file under
databaseChangeLog
node.So we made the changes and migrated the liquibase to 4.24.0 (next version after 4.23.2). But we are getting the below checksum errors(spinnaker/spinnaker#6941):
Out of two changelog files, the second file(
20190913-task-sagaids.yml
) was added withremoveChangeSetProperty
node to fixaddAfterColumn is not allowed on postgresql
issue and the first file(20180919-initial-schema.yml
) was not changed at all.After going through the checksum issues list, I tried to test with liquibase 4.25.0 which has a different behaviour.
It accepted the migration of changelog files from 3.10.3 to 4.25.0 in postgresql but without any changes to the files i.e.,
without adding the
removeChangeSetProperty
node to those changelog files that have changeSets with "afterColumn" feature.But when I tested the same set of files directly(not migrating) with 4.25.0,
addAfterColumn is not allowed on postgresql
error resurfaced.So liquibase 4.25.0 works differently for migration and first time use. We can't proceed with this kind of behaviour. Do you have any solution for this?
Steps To Reproduce
Scenario 1:
removeChangeSetProperty
node) - https://github.com/spinnaker/clouddriver/tree/release-1.33.x/clouddriver-sql/src/main/resources/db. This gives checksum error on a couple of files.Scenario 2:
Run the liquibase update using liquibase 4.25.0 on the first set of files - https://github.com/spinnaker/clouddriver/tree/release-1.32.x/clouddriver-sql/src/main/resources/db. This gives
addAfterColumn is not allowed on postgresql
error.Expected/Desired Behavior
addAfterColumn is not allowed on postgresql
error and at the same time we don't want checksum errors.Liquibase Version
4.25.0
The text was updated successfully, but these errors were encountered: