Friday, 15 March 2013

Liquibase table name prefix -


I am currently developing a prototype for a spring based plugin system. The idea is that plugins can use a linkbase change to maintain JPA institutions and database structures. In order to isolate tables created by plugins from the core system tables, the plugin must be forced to use a prefix for the table name.

JPA / Hibernate can be easily stored by using the naming strategy. But I have not found any way to store that is for liquids changes.

For example, the plugin defines a changelog like

   & Lt; / Column & gt; & Lt; Column name = "name" type = "VARCHAR (100)" & gt; & Lt; False obstacles = "wrong" /> & Lt; / Column & gt; & Lt; / CreateTable & gt; & Lt; / ChangeSet & gt;  

The table should be named "plugin_fooentity" The plugin should not know anything about the prefix because the prefix is ​​given by the plugin / core system.

It would be nice if someone could give me a signal for possible solutions.

Perhaps you can use it for?

You have to copy all the changes that you define but it should be possible

There is a subtag called regExpReplace , which you use to normalize To define the code, such as create a table (\ w *?). * and replace it with the table plugin with $ 1 .


No comments:

Post a Comment