-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Use path instead of absolutePath for resources #2122
Conversation
Thanks @liefke for adding this fix.
The PR will be prioritized according to our internal development and testing capacity. We’ll let you know when it’s ready to move to the next step or if any changes are needed. |
This change is not strictly needed anymore because the logic of handling the properties files now mainly exists in the LiquibaseCommandLine class which is replacing Main. Given that you are seeing the bug, I assume you're calling Main directly, @liefke vs. using the liquibase.bat/liquibase script? I wasn't able to replicate the issue unless I was calling Main directly. But, the change does help people that are still calling Main directly, so it's worth bringing in still. Thanks! |
… liefke-issue-2121
@nvoxland I have to admit that I'm still using a version wich has no |
The fix allows use of the pre-4.1.0 Liquibase main class to execute CLI commands that depend on a jar containing Liquibase configuration files. If the jar including the Liquibase configuration files is in the Liquibase classpath, you no longer get "missing required parameter" errors for properties that are correctly defined in a liquibase.properties file in the configuration jar. Note that by calling the the older version of main, you need to use the legacy-version of command and parameter names; for example, you need to use Pre-4.1.0 Main Class: liquibase.integration.commandline.Main Notes on Setup
Liquibase CLI Command Syntax
Test Environment |
Environment
Liquibase Version: 4.5.0
Liquibase Integration & Version: CLI
Pull Request Type
[x] Bug fix (fixes #2121)
Description
When trying to read properties files from the class path,
file.getAbsolutePath()
is used. The result is some absolute path which won't exist in the classpath on most systems.Steps To Reproduce
See the description in issue #2121
Dev Handoff Notes (Internal Use)
Links
Testing
Dev Verification
Verified the issue when using Main directly and that the fix addresses it.
Verified the fix does not cause issues when using LiquibaseCommandLine and that the reported issue is still working with the fix
┆Issue is synchronized with this Jira Bug by Unito