运行版本 3.2 时出现错误
[警告] liquibase - schema_reference.4:无法读取架构文档“ http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-3.2.xsd ”,因为 1) 找不到该文档;2)文档无法读取;3) 文档的根元素不是 。
当我查找http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-3.2.xsd时,它不存在,尽管http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-3.1 .xsd是。
我遇到了这个https://liquibase.jira.com/browse/CORE-1840,我将其解释为您不需要访问互联网即可获取 dbchangelog-3.2.xsd。当互联网可用但 .xsd 不存在时,它似乎没有帮助。
我已恢复到 3.1,但想知道 3.2 问题的根本原因。
我通过将架构与我的应用程序一起分发并在本地引用它(相对路径)来解决它。在下面的示例中,我将架构文件与更改日志放在同一文件夹中。
<databaseChangeLog xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog dbchangelog-3.1.xsd">
<!-- all the things -->
</databaseChangeLog>
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
11122 次 |
| 最近记录: |