Questions tagged [liquibase-hibernate]

Liquibase plugin for Hibernate that lets this be configured as a comparison database for Liquibase commands.

Liquibase plugin for Hibernate that lets this be configured as a comparison database for diff, diffChangeLog and generateChangeLog commands of Liquibase.

163 questions
0
votes
0 answers

Facing issue while setting up Mysql with Keycloak [java.lang.Throwable: Lock owned during cleanup: ServerService Thread Pool -- 68]

I'm setting up keycloak(in RHEL 9 Linux VM and version is rhsso-7.4.10) and mysql. Added the needed configuration changes in standalone.xml file but I'm getting below error. The logs shows some lock owned during cleanup. And I have even checked the…
0
votes
0 answers

Sharing field constraint metadata between Java DTO layer and Java Entity layer

I have a Java Entity class and a Java Data Transfer Object, each of which has it's own layer of validation based on constraints. I use Liquibase to generate changelogs (db schema) based on the state of the Java Entity classes. But there is a bug in…
bobbyrne01
  • 6,295
  • 19
  • 80
  • 150
0
votes
0 answers

Java @NotNull constraint information not part of generated Liquibase changelog when using diffChangeLog command

I have a Java Entity with an id field. I've now added a new column to the Entity but I would like to add a Java bean validation constraint of @NotNull to that field but the generated Liquibase changelog does not contain any information about the…
bobbyrne01
  • 6,295
  • 19
  • 80
  • 150
0
votes
0 answers

what should be column type for embedded type field, while writing changelog in liquibase

@Entity public class A{ private String aa; @Embedded private Addreess bb; } @Embeddable public class Address{ private String dd; } while writing the changelog below are some of the syntaxes that I have already tried -…
neo
  • 41
  • 4
0
votes
0 answers

Liquibase (diff and diffChangeLog) dataSource or dataSourceClassName or jdbcUrl is required

I'm getting the following error When I try to run Liquibase diff and diffChangeLog. The fun part is When I try to run ./gradlew update -PrunList='localEnv' It runs without any issues. The same goes for if I run the application, it runs successfully…
0
votes
0 answers

How to do data migration in liquibase for multinant architecture

We are having a multitenant architecture whereby single database is shared by multiple tenant We want to do data migration (Insert,update,delete) operation for each tenant in the same database. Each tenant is partitioned using a discriminatior…
0
votes
0 answers

Liquibase script for TABLE_PER_CLASS inheritance and @OneToMany mapping

Let "A" be a base entity with TABLE_PER_CLASS inheritance strategy. Let "B" and "C" be entity subclasses of "A". let "D" be an entity that has a @ManyToOne relationship to "A". let "A" have a @OneToMany relationship to "D". Entity classes are given…
0
votes
0 answers

Generated changelog has "add" foreign key constraint before "Drop" foreign Key constraint. liquibase jar version : 4.10

I have to upgrade liquibase-core jar from 3.4.2 to version > 4.8 for my application. In our application we are generating the changelog.xml via CLI command. we are using liquibase with Oracle PL/SQl I tried with liquibase-core 4.10 version. But the…
0
votes
1 answer

Liquibase generateChangeLog generates no data at all

I want to dump some data with liquibase maven plugin from a legacy database. So I ran this command : mvn liquibase:generateChangeLog -Poracle. The build ran successfully with no errors, but the output file (01-initial-data-dump) is empty. It also…
Dimitri
  • 8,122
  • 19
  • 71
  • 128
0
votes
1 answer

Embedded H2 Database for Spring unit test with Liquibase: No data in tables when running test

I have embedded H2 database for my Spring unit tests. The tables and data should be initialized with Liquibase. However, when a test is running, there are no data in the table. I'm using Spring 4.2.1, Liquibase 4.7.1 and H2 2.1.210. Below is my…
Janny
  • 33
  • 6
0
votes
0 answers

liquibase + Failed to load ApplicationContext

I'm developing a test for an application with many models some of them with relationships. Every time I try to run the test, it says "Failed to load ApplicationContext" error. I have a method that clean all the tables before the…
rvicente
  • 15
  • 4
0
votes
1 answer

Liquibase is not taking the configurations from application.yml

I have a spring boot application. And I have configured liquibase to create tables. I have few issues though. The tables are not getting created inside the schema and in the location provided in application.yml. Also, if i change the username from…
0
votes
0 answers

Liquibase diffChangelog between in-memory h2 database and hibernate

Is it possible to create liquibase diff changelogs while comparing in-memory H2 database with a Hibernate? I'm using a gradle liquibase plugin with a following configuration: liquibase { runList = project.ext["runList"] val today =…
andreybavt
  • 1,301
  • 4
  • 17
  • 32
0
votes
2 answers

How to create diff changelog file from JPA entities for different databases at the same time?

I want to create Liquibase changelog file based on differences between my database and my Hibernate entities for different database environments, therefore different datatypes in Oracle, SQL Server and PostgreSQL. And it's a Maven Project. So, is…
0
votes
2 answers

How we can update table A column by table B column value using liquibase yml script

I want to update table A's name column with Table B's name column value where table B's id is present in table A. I am trying this using the liquibase yml script but its not working. databaseChangeLog: - changeSet: id: update-name …
Rahul Sharma
  • 47
  • 1
  • 10