当我运行命令“mvn liquibase:generateChangeLog”时,出现该错误。我有
<outputChangeLogFile>true</outputChangeLogFile>
以便在更改日志文件而不是命令提示符中打印输出。如果我删除该行,就不会出现错误。这些是我的属性
<changeLogFile>src/main/Resources/liquibase-3.3.3-bin/db.changelog.xml</changeLogFile>
<driver>com.mysql.jdbc.Driver</driver>
<url>jdbc:mysql://localhost/test</url>
<username>****</username>
<password>********</password>
<promptOnNonLocalDatabase>false</promptOnNonLocalDatabase>
<outputChangeLogFile>true</outputChangeLogFile>
对于依赖项,我有 mysql-connector、liquibase-core 和 Snakeyaml。
[INFO] 无法使用 liquibase.serializer.core.json.JsonChangeLogSerializer 类作为 Liquibase 服务,因为 org.yaml.snakeyaml.representer.Representer 不在类路径中。
最佳答案
<outputChangeLogFile>
不是true/false
boolean 值但a String
您应该在其中提交changeLogFile的完整文件路径,例如:
<outputChangeLogFile>c:/tmp/myGeneratedChangeLogFile.xml</outputChangeLogFile>
关于java - 没有与文件名或扩展名 "true"关联的序列化程序?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/30625734/