Declaration not found databaseChangeLog

Hi, I’m new to Liquibase, and I have a somewhat hard time to get it working. I have tried Maven and Spring, and both fails with the same error. I’ve tried searching the net for the error without any great  success, so here goes.


I’m using Maven to build, and have these dependencies in my pom.xml:

  1.       org.liquibase

          liquibase-core

          2.0.5


          org.liquibase

          liquibase-maven-plugin

          2.0.5

         

                

                      org.liquibase

                      liquibase-maven-plugin

                      2.0.5

                      

                            src/main/resources/master-changelog.xml

Using Spring I get the following in the Tomcat log:

org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘liquibase’ defined in class path resource [applicationContext.xml]: Invocation of init method failed; nested exception is liquibase.exception.ChangeLogParseException: Error parsing line 4 column 138 of classpath:master-changelog.xml: cvc-elt.1: Cannot find the declaration of element ‘databaseChangeLog’.



I really hope some of you can help me.

Regards Martin




Ok, I found the error myself.


The only thing that is needed, is to change to the version of xsd to 2.0. Then everything works. I was lured by the default example of the documentation section of the liquibase site, where they use the 3.0 xsd. But…3.0 is still in beta.


Hope this may help some other unfortunates.


/Martin

Your problem was likely that you were using version 2.0.5 of the liquibase plugin, but a version 3.0 schema. If you switched to a 3.0.x build it should have worked.