How to reference a persistence unit name in Liquibase


The trouble maybe that the support in the blog post hasn’t made it into a liquibase-hibernate release yet and so you need up build the plugin yourself. Part of the reason for not having the new release is that I haven’t been able to test it out yet, so there may be some problems with it still. It’s been a lower priority area for me than the core liquibase functionality lately. Hopefully with getting 3.0 out I’ll be able to re-focus on the hibernate extension and other areas.



I am planning to integrate hibernate to liquibase. But before I have some questions to ask you : 

  1. It seems contrary to what is written in the documentation, hibernate is not supported in liquibase (please correct me if I am mistaken). When passing in the command line, a hibernate:My_HIBERNATE_CFG_FILE  as an url  as suggested in the documentation, I got an exception
  2. So my idea, is to modify the url parameter so it can read a hibernate configuration. From this configuration, get all the hibernate properties (hibernate.connection.url, hibernate.connection.driver_class, etc) to pass the parameters to Database.createDatabaseObject. 
  3. What do you think of this idea?
  4. Do I need to create an extension for that?