We’ve decided to alter Keycloak database schema to hold large json documents in user attributes and add some tracking column to user_attribute table.
Is there a ready way to package these changes in jar to be deployed in Keycloak deployments catalog so that these changes were applied on deployment with liquidbase databaseupdater.
sql code is
alter table public.user_attribute alter column value set data type text;
alter table public.user_attribute add column if not exists change_src boolean DEFAULT false;
COMMENT ON COLUMN user_attribute.change_src IS 'my comment is here'
I’ve tried to mimic keycloak-model-jpa.jar, but not luck
./src/main/resources/META-INF/beans.xml
./src/main/resources/META-INF/services/org.keycloak.connections.jpa.JpaConnectionProviderFactory
./src/main/resources/META-INF/services/org.keycloak.connections.jpa.updater.JpaUpdaterProviderFactory
./src/main/resources/META-INF/services/org.keycloak.connections.jpa.updater.liquibase.conn.LiquibaseConnectionProviderFactory
./src/main/resources/META-INF/jpa-changelog-master.xml
./src/main/resources/META-INF/jpa-changelog-rir-user-entity-value.xml
./pom.xml
Do i have to repeat source code from keycloak-model-jpa.jar for applying migrations in my own jar?