Liquibase generation issues with uniqueConstraints

Hi,
I’m using Jmix to define some simple Entities with several unique constraints on different columns. While Liquibase generation works for individual entities it happens to me, that when adding additional entities some existing unique constraints for some existing entities are not recognized anymore. Studio always want to generate new Liquibase entries when clicking “Generate Liquibase Changelog” similar to this one:

image

I can see that the corresponding constraints are already existing both in existing Liquibase XML files as well as within the database. Tried this for different database backends (MariaDB, Postgres, HSQL). If I generate the corresponding Liquibase Changelogs they are failing during execution as the unique constraints is already existing.

I know that I can “Remove and Ignore” those changes, but actually I do not want to do this as this looks like a workaround for me. Somehow I do have the feeling I’m facing a bug within Studio here. I’m using studio version 0.9.1-202 and IDEA 2021.1.1

I tried to isolate the issue in a small sample project that I committed at https://github.com/MeyerNils/jmix-uc-bug - if datastore is updated with the contained liquibase changelogs and “Generate Liquibase Changelog” is used it should hopefully show the same issue.

I’m not sure if this forum is the right place to file reports like this. If not, can you please share the right place with me?

Best regards!
Nils

Hi! Thank you for your report!

It looks like, the issue is already fixed. You can try to install the nightly build to get it. https://docs.jmix.io/jmix/0.x/studio/install.html#_nightly_builds