When i try and to start Liquibase via:
JdbcConnection liquibaseConnection = new JdbcConnection(connection);
Liquibase liquibase = new Liquibase("mychanges.xml",
new ClassLoaderResourceAccessor(),liquibaseConnection);
liquibase.update("dev");
When it is going to update i get this exception
liquibase.exception.ChangeLogParseException: Error Reading Migration File: Found 2 files that match mychanges.xml
And is caused by:
Caused by: java.io.IOException: Found 2 files that match mychanges.xml
This seems strange because when i look in the war
file it just contains one mychanges.xml
Ive tried renaming it and to move it to another location.
I do not understand why it is giving me this excepton. plees help
I found it myself. The exception thrown was not correct. It actually meant that the file could not be found. Very strange exception for this case.
With this i found out that my classpath was kinda broken.
In my case the folder path to the update sql file had non-ASCII characters in it (exp: éáű). Moving the update file into an ASCII only folder path worked.
This is with Liquibase 4.2.0 (2020-11-13 release).
[Rant]
Imagine supporting Unicode in 2020.
Liquibase team: nah
[/Rant]
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With