diff usage: dialect path

Hello, colleagues

I have a question regarding diff usage by [ERROR] Failed to execute goal org.liquibase:liquibase-maven-plugin:3.1.1:diff (default-cli) on project rlm-service: Error setting up or running Liquibase: liquibase.exception.UnexpectedLiquibaseException: liquibase.exception.DatabaseException: java.lang.ClassNotFoundException: com.my.common.db.hibernate.MyMSSQLUnicodeDialect -> [Help 1]

So, what is the correct path for dialect when it is located in the same project?

Okay. That was resolved by using standard hibernate dialect like org.hibernate.dialect.SQLServer2008Dialect.



So, after the dialect was found - the next step - is next error

 

 {main} INFO  05-02-2014 16:55:02 [LiquibaseLogger] – liquibase-hibernate Reading hibernate configuration hibernate:spring:com.my.rlm.dao.entities?dialect=org.hibernate.dialect.SQLServer2008Dialect  

 {main} INFO  05-02-2014 16:55:02 [LiquibaseLogger] – liquibase-hibernate Found package com.my.rlm.dao.entities  

 {main} INFO  05-02-2014 16:55:02 [LiquibaseLogger] – liquibase-hibernate Found dialect org.hibernate.dialect.SQLServer2008Dialect  

 {main} INFO  05-02-2014 16:55:02 [Version] – HCANN000001: Hibernate Commons Annotations {4.0.2.Final}  

 {main} INFO  05-02-2014 16:55:02 [Version] – HHH000412: Hibernate Core {4.2.4.Final}  

 {main} INFO  05-02-2014 16:55:02 [Environment] – HHH000206: hibernate.properties not found  

 {main} INFO  05-02-2014 16:55:02 [Environment] – HHH000021: Bytecode provider name : javassist  

 {main} INFO  05-02-2014 16:55:02 [Ejb3Configuration] – HHH000204: Processing PersistenceUnitInfo [

…]  

 {main} INFO  05-02-2014 16:55:03 [Dialect] – HHH000400: Using dialect: org.hibernate.dialect.SQLServer2008Dialect  

 {main} INFO  05-02-2014 16:55:03 [LiquibaseLogger] – liquibase-hibernate Using dialect org.hibernate.dialect.SQLServer2008Dialect  

[INFO] Performing Diff on database sa @ jdbc:jtds:sqlserver://localhost:1433/sample (Default Schema: dbo)

[INFO] ------------------------------------------------------------------------

[INFO] BUILD FAILURE

[INFO] ------------------------------------------------------------------------

[INFO] Total time: 7.809s

[INFO] Finished at: Wed Feb 05 16:55:03 EET 2014

[INFO] Final Memory: 26M/609M

[INFO] ------------------------------------------------------------------------

[ERROR] Failed to execute goal org.liquibase:liquibase-maven-plugin:3.1.1:diff (default-cli) on project rlm-service: Execution default-cli of goal org.liquibase:liquibase-maven-plugin:3.1.1:diff failed: An API incompatibility was encountered while executing org.liquibase:liquibase-maven-plugin:3.1.1:diff: java.lang.AbstractMethodError: liquibase.ext.hibernate.snapshot.SequenceSnapshotGenerator.replaces()[Ljava/lang/Class; 

Looks like need to debug the sources. Does anybody faced with that kind of problem? 

Where I can take the sources of liquibase-maven-plugin?

The source of the maven plugin is at github.com/liquibase/liquibase/liquibase-maven-plugin.


What version of maven are you running? And what version of liquibase?

Nathan

Does anybody know a real example where liquibase diff works using maven-plugin, spring and hibernate?

I’m pretty unsuccessfull with trying to configure it. Does not matter what DB I’m using. Oracle or MSSQL.

If danybody knows, please show me the учфьзду settings.

On my properties set I showed in previous message liquibase:generateChangeLog works well.

maven-3.0.4

liquibase-maven-plugin-3.1.1

and liquibase-3.1.1

liquibase-hibernate3-3.2


Now I’ve fixed that error. never mind. That was incorrect plugin issue due I was using modified liquibase-hibernate extension. When using all native libraries, (written by you, Nathan and community)

-

  • [INFO] ------------------------------------------------------------------------
  • [INFO] Settings----------------------------
  • [INFO]     driver: net.sourceforge.jtds.jdbc.Driver
  • [INFO]     url: jdbc:jtds:sqlserver://localhost:1433/sample
  • [INFO]     username: sa
  • [INFO]     password: *****
  • [INFO]     use empty password: false
  • [INFO]     properties file: null
  • [INFO]     properties file will override? false
  • [INFO]     prompt on non-local database? true
  • [INFO]     clear checksums? false
  • [INFO]     changeLogFile: src/main/resources/db/migration/rlm-changelog.xml
  • [INFO]     context(s): null
  • [INFO]     referenceDriver: null
  • [INFO]     referenceUrl: hibernate:spring:com.my.rlm.dao.entities?dialect=org.hibernate.dialect.SQLServer2008Dialect
  • [INFO]     referenceUsername: sa
  • [INFO]     referencePassword: sa
  • [INFO]     referenceDefaultSchema: null
  • [INFO]     diffChangeLogFile: src/main/resources/db/migration/rlm-5.0.1-changelog.xml
  • [INFO] ------------------------------------------------------------------------
  • [INFO] Executing on Database: jdbc:jtds:sqlserver://localhost:1433/sample
  • [INFO] Loading artfacts into URLClassLoader
  • [INFO] ------------------------------------------------------------------------
  • [INFO] BUILD FAILURE
  • [INFO] ------------------------------------------------------------------------
  • [INFO] Total time: 8.882s
  • [INFO] Finished at: Wed Feb 05 21:38:35 EET 2014
  • [INFO] Final Memory: 16M/604M
  • [INFO] ------------------------------------------------------------------------
  • [ERROR] Failed to execute goal org.liquibase:liquibase-maven-plugin:3.1.1:diff (default-cli) on project rlm-service: Error setting up or running Liquibase: java.lang.NullPointerException -> [Help 1]
  • [ERROR] 
  • [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
  • [ERROR] Re-run Maven using the -X switch to enable full debug logging.
  • [ERROR] 
  • [ERROR] For more information about the errors and possible solutions, please read the following articles:
  • [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
  • There may be an issue with the hibernate extension and liquibase 3.1.1. I’m looking into that.


    Nathan