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
Implement autorollback for <empty/> and <output/> changes #4103
Implement autorollback for <empty/> and <output/> changes #4103
Conversation
Initial review: Changes look right, thanks @jccampanero! Things to be aware of:
Things to worry about:
|
You are welcome @nvoxland. My pleasure to help. |
…tps://github.com/jccampanero/liquibase into jccampanero-4095_implement_autorollback_for_empty_and_output
…plement_autorollback_for_empty_and_output
Thank you very much for providing the tests cases and updating the branch @MalloD12 Daniel. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved.
Review and testing results:
Thank you, @jccampanero for your changes. They look good to me. Below what I have done:
- Manual test performed: deploy empty and output changes, and them performed rollback to both of them successfully.
- Add change sets to our rollback integration tests, and they have been executed successfully.
Things to be aware of:
- None
Things to worry about:
- None
@AMBERMW13 - @adrian-velonis1 (cc: @mariochampion ) it would be nice if we can update our documentation to reflect these changes. I have created PD-3365 for it. Thanks, |
Thank you very much Daniel. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This PR implements the auto-rollback functionality for empty
and output
change types. Rollback operations involving empty
or output
change types will no longer throw the "no inverse" error dreaded by all who love Liquibase.
- New unit tests added.
- Functional and test harness executions passing.
- No additional testing necessary.
APPROVED
Impact
Description
Currently, trying to rollback a changeset with either an
<empty />
or<output />
change, is unsupported, the library raisesliquibase.exception.RollbackImpossibleException
.Due to the nature of both type of changes
Liquibase
must support auto rollback for them.This PR address the issue by providing a convenient implementation of the
AbstractChange
'screateInverses
method.Fixes #4095.
Things to be aware of
Nothing.
Things to worry about
Nothing.
Additional Context
N/A.