--  *********************************************************************
--  Update Database Script
--  *********************************************************************
--  Change Log: META-INF/jpa-changelog-master.xml
--  Ran at: 2/1/17 8:01 AM
--  Against: dballo13@host-8-179-105.host.centralci.eng.rdu2.redhat.com@jdbc:mysql://db-02.rhev-ci-vms.eng.rdu2.redhat.com:3306/dballo13?useSSL=false
--  Liquibase version: 3.4.1
--  *********************************************************************

--  Changeset META-INF/db2-jpa-changelog-1.0.0.Final.xml::1.0.0.Final::sthorger@redhat.com
INSERT INTO dballo13.DATABASECHANGELOG (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('1.0.0.Final', 'sthorger@redhat.com', 'META-INF/db2-jpa-changelog-1.0.0.Final.xml', NOW(), 20, '7:f061c3934594ee60a9b2343f5100ae4e', 'createTable (x29), addPrimaryKey (x21), addUniqueConstraint (x6), addForeignKeyConstraint (x30)', '', 'MARK_RAN', NULL, NULL, '3.4.1');

--  Changeset META-INF/db2-jpa-changelog-1.2.0.Beta1.xml::1.2.0.Beta1::psilva@redhat.com
INSERT INTO dballo13.DATABASECHANGELOG (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('1.2.0.Beta1', 'psilva@redhat.com', 'META-INF/db2-jpa-changelog-1.2.0.Beta1.xml', NOW(), 21, '7:2e01012df20974c1c2a605ef8afe25b7', 'delete (x4), createTable (x8), addColumn (x2), addPrimaryKey (x6), addForeignKeyConstraint (x9), addUniqueConstraint (x2), addColumn, dropForeignKeyConstraint (x2), dropUniqueConstraint, renameColumn (x3), customChange, dropForeignKeyConstraint, d...', '', 'MARK_RAN', NULL, NULL, '3.4.1');

--  Changeset META-INF/db2-jpa-changelog-1.2.0.CR1.xml::1.2.0.RC1::bburke@redhat.com
INSERT INTO dballo13.DATABASECHANGELOG (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('1.2.0.RC1', 'bburke@redhat.com', 'META-INF/db2-jpa-changelog-1.2.0.CR1.xml', NOW(), 22, '7:a77ea2ad226b345e7d689d366f185c8c', 'delete (x5), createTable (x3), addColumn, createTable (x4), addPrimaryKey (x7), addForeignKeyConstraint (x6), renameColumn, addUniqueConstraint, addColumn (x2), update, dropColumn, dropForeignKeyConstraint, renameColumn, addForeignKeyConstraint, r...', '', 'MARK_RAN', NULL, NULL, '3.4.1');

--  Changeset META-INF/db2-jpa-changelog-1.4.0.xml::1.4.0::bburke@redhat.com
INSERT INTO dballo13.DATABASECHANGELOG (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('1.4.0', 'bburke@redhat.com', 'META-INF/db2-jpa-changelog-1.4.0.xml', NOW(), 23, '7:d909180b2530479a716d3f9c9eaea3d7', 'delete (x7), addColumn (x5), dropColumn, renameTable, dropForeignKeyConstraint, renameTable, addForeignKeyConstraint, update (x10), createTable (x3), customChange, dropPrimaryKey, addPrimaryKey (x4), addForeignKeyConstraint (x2), dropColumn, addCo...', '', 'MARK_RAN', NULL, NULL, '3.4.1');

--  Changeset META-INF/db2-jpa-changelog-1.8.0.xml::1.8.0::mposolda@redhat.com
INSERT INTO dballo13.DATABASECHANGELOG (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('1.8.0', 'mposolda@redhat.com', 'META-INF/db2-jpa-changelog-1.8.0.xml', NOW(), 24, '7:f987971fe6b37d963bc95fee2b27f8df', 'addColumn, createTable (x3), dropNotNullConstraint, addColumn (x2), createTable, addPrimaryKey, addUniqueConstraint, addForeignKeyConstraint (x5), addPrimaryKey, addForeignKeyConstraint (x2), addPrimaryKey, addForeignKeyConstraint, update', '', 'MARK_RAN', NULL, NULL, '3.4.1');

--  Changeset META-INF/db2-jpa-changelog-1.8.0.xml::1.8.0-2::keycloak
INSERT INTO dballo13.DATABASECHANGELOG (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('1.8.0-2', 'keycloak', 'META-INF/db2-jpa-changelog-1.8.0.xml', NOW(), 25, '7:df8bc21027a4f7cbbb01f6344e89ce07', 'dropDefaultValue, update', '', 'MARK_RAN', NULL, NULL, '3.4.1');

--  Changeset META-INF/db2-jpa-changelog-1.9.1.xml::1.9.1::keycloak
INSERT INTO dballo13.DATABASECHANGELOG (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('1.9.1', 'keycloak', 'META-INF/db2-jpa-changelog-1.9.1.xml', NOW(), 26, '7:1437310ed1305a9b93f8848f301726ce', 'modifyDataType (x2)', '', 'MARK_RAN', NULL, NULL, '3.4.1');

--  Changeset META-INF/jpa-changelog-authz-2.0.0.xml::authz-2.0.0::psilva@redhat.com
CREATE TABLE dballo13.RESOURCE_SERVER (ID VARCHAR(36) NOT NULL, CLIENT_ID VARCHAR(36) NOT NULL, ALLOW_RS_REMOTE_MGMT BIT(1) DEFAULT 0 NOT NULL, POLICY_ENFORCE_MODE VARCHAR(15) NOT NULL);

ALTER TABLE dballo13.RESOURCE_SERVER ADD PRIMARY KEY (ID);

ALTER TABLE dballo13.RESOURCE_SERVER ADD CONSTRAINT UK_AU8TT6T700S9V50BU18WS5HA6 UNIQUE (CLIENT_ID);

CREATE TABLE dballo13.RESOURCE_SERVER_RESOURCE (ID VARCHAR(36) NOT NULL, NAME VARCHAR(255) NOT NULL, URI VARCHAR(255) NULL, TYPE VARCHAR(255) NULL, ICON_URI VARCHAR(255) NULL, OWNER VARCHAR(36) NOT NULL, RESOURCE_SERVER_ID VARCHAR(36) NOT NULL);

ALTER TABLE dballo13.RESOURCE_SERVER_RESOURCE ADD PRIMARY KEY (ID);

ALTER TABLE dballo13.RESOURCE_SERVER_RESOURCE ADD CONSTRAINT FK_FRSRHO213XCX4WNKOG82SSRFY FOREIGN KEY (RESOURCE_SERVER_ID) REFERENCES dballo13.RESOURCE_SERVER (ID);

ALTER TABLE dballo13.RESOURCE_SERVER_RESOURCE ADD CONSTRAINT UK_FRSR6T700S9V50BU18WS5HA6 UNIQUE (NAME, OWNER, RESOURCE_SERVER_ID);

CREATE TABLE dballo13.RESOURCE_SERVER_SCOPE (ID VARCHAR(36) NOT NULL, NAME VARCHAR(255) NOT NULL, ICON_URI VARCHAR(255) NULL, RESOURCE_SERVER_ID VARCHAR(36) NOT NULL);

ALTER TABLE dballo13.RESOURCE_SERVER_SCOPE ADD PRIMARY KEY (ID);

ALTER TABLE dballo13.RESOURCE_SERVER_SCOPE ADD CONSTRAINT FK_FRSRSO213XCX4WNKOG82SSRFY FOREIGN KEY (RESOURCE_SERVER_ID) REFERENCES dballo13.RESOURCE_SERVER (ID);

ALTER TABLE dballo13.RESOURCE_SERVER_SCOPE ADD CONSTRAINT UK_FRSRST700S9V50BU18WS5HA6 UNIQUE (NAME, RESOURCE_SERVER_ID);

CREATE TABLE dballo13.RESOURCE_SERVER_POLICY (ID VARCHAR(36) NOT NULL, NAME VARCHAR(255) NOT NULL, DESCRIPTION VARCHAR(255) NULL, TYPE VARCHAR(255) NOT NULL, DECISION_STRATEGY VARCHAR(20) NULL, LOGIC VARCHAR(20) NULL, RESOURCE_SERVER_ID VARCHAR(36) NOT NULL);

ALTER TABLE dballo13.RESOURCE_SERVER_POLICY ADD PRIMARY KEY (ID);

ALTER TABLE dballo13.RESOURCE_SERVER_POLICY ADD CONSTRAINT FK_FRSRPO213XCX4WNKOG82SSRFY FOREIGN KEY (RESOURCE_SERVER_ID) REFERENCES dballo13.RESOURCE_SERVER (ID);

ALTER TABLE dballo13.RESOURCE_SERVER_POLICY ADD CONSTRAINT UK_FRSRPT700S9V50BU18WS5HA6 UNIQUE (NAME, RESOURCE_SERVER_ID);

CREATE TABLE dballo13.POLICY_CONFIG (POLICY_ID VARCHAR(36) NOT NULL, NAME VARCHAR(255) NOT NULL, VALUE LONGTEXT NULL);

ALTER TABLE dballo13.POLICY_CONFIG ADD PRIMARY KEY (POLICY_ID, NAME);

ALTER TABLE dballo13.POLICY_CONFIG ADD CONSTRAINT FKDC34197CF864C4E43 FOREIGN KEY (POLICY_ID) REFERENCES dballo13.RESOURCE_SERVER_POLICY (ID);

CREATE TABLE dballo13.RESOURCE_SCOPE (RESOURCE_ID VARCHAR(36) NOT NULL, SCOPE_ID VARCHAR(36) NOT NULL);

ALTER TABLE dballo13.RESOURCE_SCOPE ADD PRIMARY KEY (RESOURCE_ID, SCOPE_ID);

ALTER TABLE dballo13.RESOURCE_SCOPE ADD CONSTRAINT FK_FRSRPOS13XCX4WNKOG82SSRFY FOREIGN KEY (RESOURCE_ID) REFERENCES dballo13.RESOURCE_SERVER_RESOURCE (ID);

ALTER TABLE dballo13.RESOURCE_SCOPE ADD CONSTRAINT FK_FRSRPS213XCX4WNKOG82SSRFY FOREIGN KEY (SCOPE_ID) REFERENCES dballo13.RESOURCE_SERVER_SCOPE (ID);

CREATE TABLE dballo13.RESOURCE_POLICY (RESOURCE_ID VARCHAR(36) NOT NULL, POLICY_ID VARCHAR(36) NOT NULL);

ALTER TABLE dballo13.RESOURCE_POLICY ADD PRIMARY KEY (RESOURCE_ID, POLICY_ID);

ALTER TABLE dballo13.RESOURCE_POLICY ADD CONSTRAINT FK_FRSRPOS53XCX4WNKOG82SSRFY FOREIGN KEY (RESOURCE_ID) REFERENCES dballo13.RESOURCE_SERVER_RESOURCE (ID);

ALTER TABLE dballo13.RESOURCE_POLICY ADD CONSTRAINT FK_FRSRPP213XCX4WNKOG82SSRFY FOREIGN KEY (POLICY_ID) REFERENCES dballo13.RESOURCE_SERVER_POLICY (ID);

CREATE TABLE dballo13.SCOPE_POLICY (SCOPE_ID VARCHAR(36) NOT NULL, POLICY_ID VARCHAR(36) NOT NULL);

ALTER TABLE dballo13.SCOPE_POLICY ADD PRIMARY KEY (SCOPE_ID, POLICY_ID);

ALTER TABLE dballo13.SCOPE_POLICY ADD CONSTRAINT FK_FRSRPASS3XCX4WNKOG82SSRFY FOREIGN KEY (SCOPE_ID) REFERENCES dballo13.RESOURCE_SERVER_SCOPE (ID);

ALTER TABLE dballo13.SCOPE_POLICY ADD CONSTRAINT FK_FRSRASP13XCX4WNKOG82SSRFY FOREIGN KEY (POLICY_ID) REFERENCES dballo13.RESOURCE_SERVER_POLICY (ID);

CREATE TABLE dballo13.ASSOCIATED_POLICY (POLICY_ID VARCHAR(36) NOT NULL, ASSOCIATED_POLICY_ID VARCHAR(36) NOT NULL);

ALTER TABLE dballo13.ASSOCIATED_POLICY ADD PRIMARY KEY (POLICY_ID, ASSOCIATED_POLICY_ID);

ALTER TABLE dballo13.ASSOCIATED_POLICY ADD CONSTRAINT FK_FRSRPAS14XCX4WNKOG82SSRFY FOREIGN KEY (POLICY_ID) REFERENCES dballo13.RESOURCE_SERVER_POLICY (ID);

ALTER TABLE dballo13.ASSOCIATED_POLICY ADD CONSTRAINT FK_FRSR5S213XCX4WNKOG82SSRFY FOREIGN KEY (ASSOCIATED_POLICY_ID) REFERENCES dballo13.RESOURCE_SERVER_POLICY (ID);

INSERT INTO dballo13.DATABASECHANGELOG (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('authz-2.0.0', 'psilva@redhat.com', 'META-INF/jpa-changelog-authz-2.0.0.xml', NOW(), 27, '7:9cc98082921330d8d9266decdd4bd658', 'createTable, addPrimaryKey, addUniqueConstraint, createTable, addPrimaryKey, addForeignKeyConstraint, addUniqueConstraint, createTable, addPrimaryKey, addForeignKeyConstraint, addUniqueConstraint, createTable, addPrimaryKey, addForeignKeyConstrain...', '', 'EXECUTED', NULL, NULL, '3.4.1');

--  Changeset META-INF/jpa-changelog-authz-2.5.1.xml::authz-2.5.1::psilva@redhat.com
UPDATE dballo13.RESOURCE_SERVER_POLICY SET TYPE = 'rules' WHERE TYPE = 'drools';

INSERT INTO dballo13.DATABASECHANGELOG (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('authz-2.5.1', 'psilva@redhat.com', 'META-INF/jpa-changelog-authz-2.5.1.xml', NOW(), 28, '7:03d64aeed9cb52b969bd30a7ac0db57e', 'update', '', 'EXECUTED', NULL, NULL, '3.4.1');

--  Changeset META-INF/jpa-changelog-2.1.0.xml::2.1.0::bburke@redhat.com
CREATE TABLE dballo13.BROKER_LINK (IDENTITY_PROVIDER VARCHAR(255) NOT NULL, STORAGE_PROVIDER_ID VARCHAR(255) NULL, REALM_ID VARCHAR(36) NOT NULL, BROKER_USER_ID VARCHAR(255) NULL, BROKER_USERNAME VARCHAR(255) NULL, TOKEN TEXT NULL, USER_ID VARCHAR(255) NOT NULL);

CREATE TABLE dballo13.FED_USER_ATTRIBUTE (ID VARCHAR(36) NOT NULL, NAME VARCHAR(255) NOT NULL, USER_ID VARCHAR(255) NOT NULL, REALM_ID VARCHAR(36) NOT NULL, STORAGE_PROVIDER_ID VARCHAR(36) NULL, VALUE VARCHAR(2024) NULL);

CREATE TABLE dballo13.FED_USER_CONSENT (ID VARCHAR(36) NOT NULL, CLIENT_ID VARCHAR(36) NOT NULL, USER_ID VARCHAR(255) NOT NULL, REALM_ID VARCHAR(36) NOT NULL, STORAGE_PROVIDER_ID VARCHAR(36) NULL);

CREATE TABLE dballo13.FED_USER_CONSENT_ROLE (USER_CONSENT_ID VARCHAR(36) NOT NULL, ROLE_ID VARCHAR(36) NOT NULL);

CREATE TABLE dballo13.FED_USER_CONSENT_PROT_MAPPER (USER_CONSENT_ID VARCHAR(36) NOT NULL, PROTOCOL_MAPPER_ID VARCHAR(36) NOT NULL);

CREATE TABLE dballo13.FED_USER_CREDENTIAL (ID VARCHAR(36) NOT NULL, DEVICE VARCHAR(255) NULL, HASH_ITERATIONS INT NULL, SALT BLOB NULL, TYPE VARCHAR(255) NULL, VALUE VARCHAR(255) NULL, CREATED_DATE BIGINT NULL, COUNTER INT DEFAULT 0 NULL, DIGITS INT DEFAULT 6 NULL, PERIOD INT DEFAULT 30 NULL, ALGORITHM VARCHAR(36) DEFAULT 'HmacSHA1' NULL, USER_ID VARCHAR(255) NOT NULL, REALM_ID VARCHAR(36) NOT NULL, STORAGE_PROVIDER_ID VARCHAR(36) NULL);

CREATE TABLE dballo13.FED_USER_GROUP_MEMBERSHIP (GROUP_ID VARCHAR(36) NOT NULL, USER_ID VARCHAR(255) NOT NULL, REALM_ID VARCHAR(36) NOT NULL, STORAGE_PROVIDER_ID VARCHAR(36) NULL);

CREATE TABLE dballo13.FED_USER_REQUIRED_ACTION (REQUIRED_ACTION VARCHAR(255) DEFAULT ' ' NOT NULL, USER_ID VARCHAR(255) NOT NULL, REALM_ID VARCHAR(36) NOT NULL, STORAGE_PROVIDER_ID VARCHAR(36) NULL);

CREATE TABLE dballo13.FED_USER_ROLE_MAPPING (ROLE_ID VARCHAR(36) NOT NULL, USER_ID VARCHAR(255) NOT NULL, REALM_ID VARCHAR(36) NOT NULL, STORAGE_PROVIDER_ID VARCHAR(36) NULL);

CREATE TABLE dballo13.COMPONENT_CONFIG (ID VARCHAR(36) NOT NULL, COMPONENT_ID VARCHAR(36) NOT NULL, NAME VARCHAR(255) NOT NULL, VALUE VARCHAR(4000) NULL);

CREATE TABLE dballo13.COMPONENT (ID VARCHAR(36) NOT NULL, NAME VARCHAR(255) NULL, PARENT_ID VARCHAR(36) NULL, PROVIDER_ID VARCHAR(36) NULL, PROVIDER_TYPE VARCHAR(255) NULL, REALM_ID VARCHAR(36) NULL);

ALTER TABLE dballo13.BROKER_LINK ADD PRIMARY KEY (IDENTITY_PROVIDER, USER_ID);

ALTER TABLE dballo13.FED_USER_ATTRIBUTE ADD PRIMARY KEY (ID);

ALTER TABLE dballo13.FED_USER_CONSENT ADD PRIMARY KEY (ID);

ALTER TABLE dballo13.FED_USER_CONSENT_ROLE ADD PRIMARY KEY (USER_CONSENT_ID, ROLE_ID);

ALTER TABLE dballo13.FED_USER_CONSENT_PROT_MAPPER ADD PRIMARY KEY (USER_CONSENT_ID, PROTOCOL_MAPPER_ID);

ALTER TABLE dballo13.FED_USER_CREDENTIAL ADD PRIMARY KEY (ID);

ALTER TABLE dballo13.FED_USER_GROUP_MEMBERSHIP ADD PRIMARY KEY (GROUP_ID, USER_ID);

ALTER TABLE dballo13.FED_USER_ROLE_MAPPING ADD PRIMARY KEY (ROLE_ID, USER_ID);

ALTER TABLE dballo13.FED_USER_REQUIRED_ACTION ADD PRIMARY KEY (REQUIRED_ACTION, USER_ID);

ALTER TABLE dballo13.COMPONENT ADD PRIMARY KEY (ID);

ALTER TABLE dballo13.COMPONENT_CONFIG ADD PRIMARY KEY (ID);

ALTER TABLE dballo13.COMPONENT ADD CONSTRAINT FK_COMPONENT_REALM FOREIGN KEY (REALM_ID) REFERENCES dballo13.REALM (ID);

ALTER TABLE dballo13.COMPONENT_CONFIG ADD CONSTRAINT FK_COMPONENT_CONFIG FOREIGN KEY (COMPONENT_ID) REFERENCES dballo13.COMPONENT (ID);

INSERT INTO dballo13.DATABASECHANGELOG (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('2.1.0', 'bburke@redhat.com', 'META-INF/jpa-changelog-2.1.0.xml', NOW(), 29, '7:e01599a82bf8d6dc22a9da506e22e868', 'createTable (x11), addPrimaryKey (x11), addForeignKeyConstraint (x2)', '', 'EXECUTED', NULL, NULL, '3.4.1');

--  Changeset META-INF/jpa-changelog-2.2.0.xml::2.2.0::bburke@redhat.com
ALTER TABLE dballo13.ADMIN_EVENT_ENTITY ADD RESOURCE_TYPE VARCHAR(64) NULL;

CREATE TABLE dballo13.CREDENTIAL_ATTRIBUTE (ID VARCHAR(36) NOT NULL, CREDENTIAL_ID VARCHAR(36) NOT NULL, NAME VARCHAR(255) NOT NULL, VALUE VARCHAR(4000) NULL);

CREATE TABLE dballo13.FED_CREDENTIAL_ATTRIBUTE (ID VARCHAR(36) NOT NULL, CREDENTIAL_ID VARCHAR(36) NOT NULL, NAME VARCHAR(255) NOT NULL, VALUE VARCHAR(4000) NULL);

ALTER TABLE dballo13.CREDENTIAL MODIFY VALUE VARCHAR(4000);

ALTER TABLE dballo13.FED_CREDENTIAL_ATTRIBUTE ADD CONSTRAINT FK_FED_CRED_ATTR FOREIGN KEY (CREDENTIAL_ID) REFERENCES dballo13.FED_USER_CREDENTIAL (ID);

ALTER TABLE dballo13.CREDENTIAL_ATTRIBUTE ADD CONSTRAINT FK_CRED_ATTR FOREIGN KEY (CREDENTIAL_ID) REFERENCES dballo13.CREDENTIAL (ID);

INSERT INTO dballo13.DATABASECHANGELOG (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('2.2.0', 'bburke@redhat.com', 'META-INF/jpa-changelog-2.2.0.xml', NOW(), 30, '7:53188c3eb1107546e6f765835705b6c1', 'addColumn, createTable (x2), modifyDataType, addForeignKeyConstraint (x2)', '', 'EXECUTED', NULL, NULL, '3.4.1');

--  Changeset META-INF/jpa-changelog-2.3.0.xml::2.3.0::bburke@redhat.com
CREATE TABLE dballo13.FEDERATED_USER (ID VARCHAR(255) NOT NULL, STORAGE_PROVIDER_ID VARCHAR(255) NULL, REALM_ID VARCHAR(36) NOT NULL);

ALTER TABLE dballo13.FEDERATED_USER ADD PRIMARY KEY (ID);

ALTER TABLE dballo13.USER_ENTITY ALTER TOTP DROP DEFAULT;

ALTER TABLE dballo13.USER_ENTITY DROP COLUMN TOTP;

ALTER TABLE dballo13.IDENTITY_PROVIDER ADD PROVIDER_DISPLAY_NAME VARCHAR(255) NULL;

ALTER TABLE dballo13.COMPONENT ADD SUB_TYPE VARCHAR(255) NULL;

INSERT INTO dballo13.COMPONENT (ID, REALM_ID, PARENT_ID, NAME, PROVIDER_ID, PROVIDER_TYPE) VALUES ('8a2b3c6c-c8c8-4eb9-8f43-1b80baf62b85', 'master', 'master', 'rsa', 'rsa', 'org.keycloak.keys.KeyProvider');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('b4851e1b-a61d-4111-9629-e629a34991a1', '8a2b3c6c-c8c8-4eb9-8f43-1b80baf62b85', 'priority', '100');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('174ba054-8d66-4959-8345-386b152d2540', '8a2b3c6c-c8c8-4eb9-8f43-1b80baf62b85', 'privateKey', 'MIIEowIBAAKCAQEAiU54OXoCbHy0L0gHn1yasctcnKHRU1pHFIJnWvaI7rClJydet9dDJaiYXOxMKseiBm3eYznfN3cPyU8udYmRnMuKjiocZ77LT2IEttAjXb6Ggazx7loriFHRy0IOJeX4KxXhAPWmxqa3mkFNfLBEvFqVaBgUDHQ60cmnPvNSHYudBTW9K80s8nvmP2pso7HTwWJ1+Xatj1Ey/gTmB3CXlyqBegGWC9TeuErEYpYhdh+11TVWasgMBZyUCtL3NRPaBuhaPg1LpW8lWGk05nS+YM6dvTk3Mppv+z2RygEpxyO09oT3b4G+Zfwit1STqn0AvDTGzINdoKcNtFScV0j8TwIDAQABAoIBAHcbPKsPLZ8SJfOF1iblW8OzFulAbaaSf2pJHIMJrQrw7LKkMkPjVXoLX+/rgr7xYZmWIP2OLBWfEHCeYTzQUyHiZpSf7vgHx7Fa45/5uVQOe/ttHIiYa37bCtP4vvEdJkOpvP7qGPvljwsebqsk9Ns28LfVez66bHOjK5Mt2yOIulbTeEs7ch//h39YwKJv96vc+CHbV2O6qoOxZessO6y+287cOBvbFXmS2GaGle5Nx/EwncBNS4b7czoetmm70+9ht3yX+kxaP311YUT31KQjuaJt275kOiKsrXr27PvgO++bsIyGuSzqyS7G7fmxF2zUyphEqEpalyDGMKMnrAECgYEA1fCgFox03rPDjm0MhW/ThoS2Ld27sbWQ6reS+PBMdUTJZVZIU1D2//h6VXDnlddhk6avKjA4smdy1aDKzmjz3pt9AKn+kgkXqtTC2fD3wp+fC9hND0z+rQPGe/Gk7ZUnTdsqnfyowxr+woIgzdnRukOUrG+xQiP3RUUT7tt6NQECgYEApEz2xvgqMm+9/f/YxjLdsFUfLqc4WlafB863stYEVqlCYy5ujyo0VQ0ahKSKJkLDnf52+aMUqPOpwaGePpu3O6VkvpcKfPY2MUlZW7/6Sa9et9hxNkdTS7Gui2d1ELpaCBe1Bc62sk8EA01iHXE1PpvyUqDWrhNh+NrDICA9oU8CgYBgGDYACtTP11TmW2r9YK5VRLUDww30k4ZlN1GnyV++aMhBYVEZQ0u+y+A/EnijIFwu0vbo70H4OGknNZMCxbeMbLDoJHM5KyZbUDe5ZvgSjloFGwH59m6KTiDQOUkIgi9mVCQ/VGaFRFHcElEjxUvj60kTbxPijn8ZuR5r8l9hAQKBgQCQ9jL5pHWeoIayN20smi6M6N2lTPbkhe60dcgQatHTIG2pkosLl8IqlHAkPgSB84AiwyR351JQKwRJCm7TcJI/dxMnMZ6YWKfB3qSP1hdfsfJRJQ/mQxIUBAYrizF3e+P5peka4aLCOgMhYsJBlePThMZN7wja99EGPwXQL4IQ8wKBgB8Nis1lQK6Z30GCp9u4dYleGfEP71Lwqvk/eJb89/uz0fjF9CTpJMULFc+nA5u4yHP3LFnRg3zCU6aEwfwUyk4GH9lWGV/qIAisQtgrCEraVe4qxz0DVE59C7qjO26IhU2U66TEzPAqvQ3zqey+woDn/cz/JMWK1vpcSk+TKn3K');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('f4ac4ba0-dd52-4a40-8612-af9dec24f6bb', '8a2b3c6c-c8c8-4eb9-8f43-1b80baf62b85', 'certificate', 'MIICmzCCAYMCBgFXt/Tg9TANBgkqhkiG9w0BAQsFADARMQ8wDQYDVQQDDAZtYXN0ZXIwHhcNMTYxMDEyMDgxMjQxWhcNMjYxMDEyMDgxNDIxWjARMQ8wDQYDVQQDDAZtYXN0ZXIwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCJTng5egJsfLQvSAefXJqxy1ycodFTWkcUgmda9ojusKUnJ16310MlqJhc7Ewqx6IGbd5jOd83dw/JTy51iZGcy4qOKhxnvstPYgS20CNdvoaBrPHuWiuIUdHLQg4l5fgrFeEA9abGpreaQU18sES8WpVoGBQMdDrRyac+81Idi50FNb0rzSzye+Y/amyjsdPBYnX5dq2PUTL+BOYHcJeXKoF6AZYL1N64SsRiliF2H7XVNVZqyAwFnJQK0vc1E9oG6Fo+DUulbyVYaTTmdL5gzp29OTcymm/7PZHKASnHI7T2hPdvgb5l/CK3VJOqfQC8NMbMg12gpw20VJxXSPxPAgMBAAEwDQYJKoZIhvcNAQELBQADggEBAC54wFHL8tmrksq4OzatzNUM+R+3Hu/VXX3T44dwg0EvXzGW45sME+gKCuleU1PabIrr6oFm0bBMTdxgE2hbLWpYbU3OcsjArpCeCsOlxrAkqhVQN161J+tp77JkDMgArFdwe3wh5bhvLaOZSt6Fsq+oo16CXG1obe1feyaK3+sU3YuDUIHE01UYtvwtfDsYBC+VDyTdNDbB15WcdRoGljJY/JiT0JHdmAfq8qdGDuxGocIV0lSB8bO5JwF/WCmKqMrnh5j1NfGcE1g26Hbz2RmDs17X0K10Okzs/qz1YZqDjPVYiU//VFQQro71/D35dPOJv8mQMjhjNaXScL44h7w=');

INSERT INTO dballo13.COMPONENT (ID, REALM_ID, PARENT_ID, NAME, PROVIDER_ID, PROVIDER_TYPE) VALUES ('86eb6f17-8dff-4ef6-bc17-57b844720511', 'Migration', 'Migration', 'rsa', 'rsa', 'org.keycloak.keys.KeyProvider');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('7a3d77cf-d7ce-4909-92fa-52ac297683ba', '86eb6f17-8dff-4ef6-bc17-57b844720511', 'priority', '100');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('9942be83-edd9-4182-abba-ac88c5b21b00', '86eb6f17-8dff-4ef6-bc17-57b844720511', 'privateKey', 'MIIEpAIBAAKCAQEApt6gCllWkVTZ7fy/oRIx6Bxjt9x3eKKyKGFXvN4iaafrNqpYU9lcqPngWJ9DyXGqUf8RpjPaQWiLWLxjw3xGBqLk2E1/Frb9e/dy8rj//fHGq6bujN1iguzyFwxPGT5Asd7jflRI3qU04M8JE52PArqPhGL2Fn+FiSK5SWRIGm+hVL7Ck/E/tVxM25sFG1/UTQqvrROm4q76TmP8FsyZaTLVf7cCwW2QPIX0N5HTVb3QbBb5KIsk4kKmk/g7uUxS9r42tu533LISzRr5CTyWZAL2XFRuF2RrKdE8gwqkEubw6sDmB2mE0EoPdY1DUhBQgVP/5rwJrCtTsUBR2xdEYQIDAQABAoIBAFbbsNBSOlZBpYJUOmcb8nBQPrOYhXN8tGGCccn0klMOvcdhmcJjdPDbyCQ5Gm7DxJUTwNsTSHsdcNMKlJ9Pk5+msJnKlOl87KrXXbTsCQvlCrWUmb0nCzz9GvJWTOHl3oT3cND0DE4gDksqWR4luCgCdevCGzgQvrBoK6wBD+r578uEW3iw10hnJ0+wnGiw8IvPzE1a9xbY4HD8/QrYdaLxuLb/aC1PDuzrz0cOjnvPkrws5JrbUSnbFygJiOv1z4l2Q00uGIxlHtXdwQBnTZZjVi4vOec2BYSHffgwDYEZIglw1mnrV7y0N1nnPbtJK/cegIkXoBQHXm8Q99TrWMUCgYEA9au86qcwrXZZg5H4BpR5cpy0MSkcKDbA1aRL1cAyTCqJxsczlAtLhFADF+NhnlXj4y7gwDEYWrz064nF73I+ZGicvCiyOy+tCTugTyTGS+XR948ElDMS6PCUUXsotS3dKa0b3c9wd2mxeddTjq/ArfgEVZJ6fE1KtjLt9dtfA+8CgYEAreK3JsvjR5b/Xct28TghYUU7Qnasombb/shqqy8FOMjYUr5OUm/OjNIgoCqhOlE8oQDJ4dOZofNSa7tL+oM8Gmbal+E3fRzxnx/9/EC4QV6sVaPLTIyk7EPfKTcZuzH7+BNZtAziTxJw9d6YJQRbkpg92EZIEoR8iDj2Xs5xrK8CgYEAwMVWwwYX8zT3vn7ukTM2LRH7bsvkVUXJgJqgCwT6Mrv6SmkK9vL5+cPS+Y6pjdW1sRGauBSOGL1Grf/4ug/6F03jFt4UJM8fRyxreU7Q7sNSQ6AMpsGA6BnHODycz7ZCYa59PErG5FyiL4of/cm5Nolz1TXQOPNpWZiTEqVlZC8CgYA4YPbjVF4nuxSnU64H/hwMjsbtAM9uhI016cN0J3W4+J3zDhMU9X1x+Tts0wWdg/N1fGz4lIQOl3cUyRCUc/KL2OdtMS+tmDHbVyMho9ZaE5kq10W2Vy+uDz+O/HeSU12QDK4cC8Vgv+jyPy7zaZtLR6NduUPrBRvfiyCOkr8WrwKBgQCY0h4RCdNFhr0KKLLmJipAtV8wBCGcg1jY1KoWKQswbcykfBKwHbF6EooVqkRW0ITjWB7ZZCf8TnSUxe0NXCUAkVBrhzS4DScgtoSZYOOUaSHgOxpfwgnQ3oYotKi98Yg3IsaLs1j4RuPG5Sp1z6o+ELP1uvr8azyn9YlLa+523Q==');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('743021aa-8d4b-4fd1-8395-50c17eed7493', '86eb6f17-8dff-4ef6-bc17-57b844720511', 'certificate', 'MIICoTCCAYkCBgFXt/t9TjANBgkqhkiG9w0BAQsFADAUMRIwEAYDVQQDDAlNaWdyYXRpb24wHhcNMTYxMDEyMDgxOTU0WhcNMjYxMDEyMDgyMTM0WjAUMRIwEAYDVQQDDAlNaWdyYXRpb24wggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCm3qAKWVaRVNnt/L+hEjHoHGO33Hd4orIoYVe83iJpp+s2qlhT2Vyo+eBYn0PJcapR/xGmM9pBaItYvGPDfEYGouTYTX8Wtv1793LyuP/98carpu6M3WKC7PIXDE8ZPkCx3uN+VEjepTTgzwkTnY8Cuo+EYvYWf4WJIrlJZEgab6FUvsKT8T+1XEzbmwUbX9RNCq+tE6birvpOY/wWzJlpMtV/twLBbZA8hfQ3kdNVvdBsFvkoiyTiQqaT+Du5TFL2vja27nfcshLNGvkJPJZkAvZcVG4XZGsp0TyDCqQS5vDqwOYHaYTQSg91jUNSEFCBU//mvAmsK1OxQFHbF0RhAgMBAAEwDQYJKoZIhvcNAQELBQADggEBAFtPdVUB65dAP6v2wu8idPkkqRaP5gmcOuOt2+8/slx7RvO/FFwzFvAqroqmpaKJ53daewZwIG4Wzu4lziqYnD3F3YoqxqUY8ID58SLm9a6XF6aYka7TxXJnZgmy7v1ZWcbbTinvUC7S1m23imT7779cWj5NkkXSM/R+RWB8ZAQCpy9pg7iElAMTlqAp31pCntNG3l1O13A6t5eN3Af474T0FjVaXIEG/PLcRmF/5kTwmkYy5Av1v2vmyLBYXKNUrWwjeTGEEX0+j9AkcF79D1GpdKZpvuC0wxOrOgHLiR9DpGucMJajx+RA8zbAAj5C1A5JfkKBZPh2jMQ06c2eAAM=');

INSERT INTO dballo13.COMPONENT (ID, REALM_ID, PARENT_ID, NAME, PROVIDER_ID, PROVIDER_TYPE) VALUES ('0b7198cb-6705-4c5e-94c3-21dbc5b9d494', 'Migration2', 'Migration2', 'rsa', 'rsa', 'org.keycloak.keys.KeyProvider');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('872066f8-1531-43fe-b667-d87f5d7dffb4', '0b7198cb-6705-4c5e-94c3-21dbc5b9d494', 'priority', '100');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('5fddd239-e0d5-4de9-a289-044ace17edbc', '0b7198cb-6705-4c5e-94c3-21dbc5b9d494', 'privateKey', 'MIIEowIBAAKCAQEAgzWQuDVTEV0It1322wbNGKc9SSxG9rayxRPbG7YSj4cMP6BO4eblRoUw5ebKCng+OD5FhVIlBnkzoGOCnL/VXaQnEQbqlNwO/N5Ca6/4Mc/MedX8LamlYbo+varVQAJQTZSMp9+NeQZZbSQ3L9EYhsCUdPANwVqYn/CM37FpNZDYfBDxEtaxwP6suuVfUJcupx+YayUbIQ2ZP/FgTE1b/3C3J7nCAhDYlJTag84FOkVhPL2xI9T2XozyHVVwSsPTQDPK+HrTTnE9UqBsglz3ASXElixSs1WKef3iTFiU77p8pjTcxfm3xaE9eLD3tK805KQForBZ7pYSbgp8bY9F7wIDAQABAoIBACH3jf2CIH0QPp9pvew5uIK3WNBGnCBmb6VBXKmx2uA5L9yQ3ZrxsU0uUdhShN9s/X6F8G1xNJCWc90Dpd56cvwI8OwhhD0BMwgXac6DAZezmdW4pc4UavH/yxpCzW4Cq1NKL5eN8gvwrtnoVDkWwmiwFj6nnof9siFFntKSFRB+isvzj+X4wDb0Qc39eeyRdcXGxEwfgVDWIDKCdvW942aEl23WL8LBVshRj/PFu9m7htaoLMk3r27yaFZmzPWbAG/gojCA9EhndpmPrUteReboYcDWc6l3zgdGqxHVyR+JHWdeRMnsdouPoa+2C6nY4THzgkp+NEOsuxc8msTssWECgYEA7cl/SZJrCXIA2Q58mRis5W3F9ZsVx1O+yHpqrXX6a6+MPZ/ERTGY8zU8QINCPmJOGt5APeq9eZNtpaDrGb3KD8Y341LKjkF8uVMg8HJUttHrRZtHm0M+8a7Yf8oIynOkCUaUvnxEerpNPF3TKySfCer1vd9z+GUE3KTj12gAAscCgYEAjUJNJwp5oIbvNZEzFsNJV3MK1xFOxR1/zxoqXKVNVqtz4aOEaqnDd/t7XM+pkW/FSp8V+mZC1+vl4X4mBlTYWxuSMLifglJWlDflgOfPvQNYbDDg94mBleFQ/J7Y4ArEBTdu7QEcaPPwAXocusoeEG+yQpon+CCfkDMUkWIIe5kCgYEAuJT2euzuq7lUUSm+rLUL2VjaFypYwI8QhN0KHDZ9usPdkCSKHdA/U2OartV1QanbyV2G7sleZZZ8wdplRWkfBhmvXoXw+HZ7U/zkj+GgQv42rKS59BtCLCe2pZP2OPmFdzHT2v3pxn8B339Roabe0bsTIV3ozwPTv1c8CgUQJRcCgYBflOJRrXPZHBSWYXZ5S5C/3HcUSYDMPgayYxkQ8UUghQj3P8akydQaxo6VoWoyn7eWo4iikzldkyBMcShXlmeDVmeYEgTUkNRGnH/ttm1Jjw7wvi4rMN7/RKOhG/bRulci1Hx5YAwSNCVNSoxQE9097+ZlzJuI+MIfN4EOUpA82QKBgBdxizw7x2v4g8s2maBcuA1YhncIgPQFnAWHzI7kn5dNHImHRlcM56mEW82u3kZJDVmxM6eNwbI9L+tqPcWwPmI3/NJB970kmVSGWIE7B2AfINkCyAe2fGZaUUxbmNi/01BPIUdRHHxYQsKEdSozi5bET0lLmVnOSBU3qPq9yJZx');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('fbba9bb7-7b4b-4e97-80fc-5920fff057bc', '0b7198cb-6705-4c5e-94c3-21dbc5b9d494', 'certificate', 'MIICozCCAYsCBgFZkvmqVDANBgkqhkiG9w0BAQsFADAVMRMwEQYDVQQDDApNaWdyYXRpb24yMB4XDTE3MDExMjEzNTczMloXDTI3MDExMjEzNTkxMlowFTETMBEGA1UEAwwKTWlncmF0aW9uMjCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAIM1kLg1UxFdCLdd9tsGzRinPUksRva2ssUT2xu2Eo+HDD+gTuHm5UaFMOXmygp4Pjg+RYVSJQZ5M6Bjgpy/1V2kJxEG6pTcDvzeQmuv+DHPzHnV/C2ppWG6Pr2q1UACUE2UjKffjXkGWW0kNy/RGIbAlHTwDcFamJ/wjN+xaTWQ2HwQ8RLWscD+rLrlX1CXLqcfmGslGyENmT/xYExNW/9wtye5wgIQ2JSU2oPOBTpFYTy9sSPU9l6M8h1VcErD00Azyvh6005xPVKgbIJc9wElxJYsUrNVinn94kxYlO+6fKY03MX5t8WhPXiw97SvNOSkBaKwWe6WEm4KfG2PRe8CAwEAATANBgkqhkiG9w0BAQsFAAOCAQEAQh8J7vFKuj3GN8LBM1FkQopMJZBCc07ZtgWGMx2qEiQKaIgevUdwDm6hjbij06b4oZHWxtC6A8CnVD6R2Uf8+gk0j26xnOJkMNWGw0jpYpKIIpdGHT/lcvnS8ao/c+DZr8CNXZNWeVaDdOv/IDi8+B9n9qwgsGQDHCZ5VT20yBPaJTNUyqVefAtL680yIGz46bI+U7Iipz+1FlFjvDwjSKhOhLPtpD5SP5/AVDbYtD/UPh0yLHSva+/XanGQjhveKVdApoViDgVcdAlj3WO1+L4hVPHfasVLDlhSuDLaFTrPH6Yepv5CxvMpdPOJjAJI4EqMWWxslAjFEV78ya7gKw==');

ALTER TABLE dballo13.REALM DROP COLUMN CODE_SECRET;

ALTER TABLE dballo13.REALM DROP COLUMN PRIVATE_KEY;

ALTER TABLE dballo13.REALM DROP COLUMN PUBLIC_KEY;

ALTER TABLE dballo13.REALM DROP COLUMN CERTIFICATE;

ALTER TABLE dballo13.USER_CONSENT ADD CREATED_DATE BIGINT NULL, ADD LAST_UPDATED_DATE BIGINT NULL;

INSERT INTO dballo13.DATABASECHANGELOG (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('2.3.0', 'bburke@redhat.com', 'META-INF/jpa-changelog-2.3.0.xml', NOW(), 31, '7:d6e6f3bc57a0c5586737d1351725d4d4', 'createTable, addPrimaryKey, dropDefaultValue, dropColumn, addColumn (x2), customChange, dropColumn (x4), addColumn', '', 'EXECUTED', NULL, NULL, '3.4.1');

--  Changeset META-INF/jpa-changelog-2.4.0.xml::2.4.0::bburke@redhat.com
INSERT INTO dballo13.COMPONENT (ID, REALM_ID, PARENT_ID, NAME, PROVIDER_ID, PROVIDER_TYPE) VALUES ('4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'Migration2', 'Migration2', 'ldap-provider', 'ldap', 'org.keycloak.storage.UserStorageProvider');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('4e580bf7-99e8-4f00-a310-8545cb461ca2', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'priority', '2');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('6e1da666-b603-444b-93b0-8457fe68203f', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'fullSyncPeriod', '-1');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('b293c3ef-1121-4d10-a68f-6b1fb61f6902', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'changedSyncPeriod', '-1');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('0e748a77-de8a-4708-8754-c713bdc59732', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'lastSync', '0');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('2c7332c3-2141-4e4a-b2cc-d47ffd3858d9', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'allowKerberosAuthentication', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('d37237d1-b4f7-4db2-8f2c-130152ccbdef', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'authType', 'none');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('ffd8eb59-f47b-4127-a228-4f30a239b446', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'batchSizeForSync', '1001');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('ab4ba0bf-5e74-4278-87cf-413b8a5981b2', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'connectionPooling', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('be165240-0bed-4244-94bc-383599123a3d', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'connectionUrl', 'http://localhost');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('3f4d4f0b-ffcb-4199-be25-6a9502ed2095', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'debug', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('51f04c05-867a-4181-a8ee-8eb5206bdc26', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'editMode', 'READ_ONLY');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('f6f6ffbb-3dbf-4655-b288-4c93ee92146f', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'kerberosRealm', 'realm');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('2fa22012-b120-4974-8731-71206e1e0a37', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'keyTab', 'keytab');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('fe94daf9-dae8-4a80-b91a-18ec2fc9e945', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'pagination', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('ef247dc8-6bec-4749-a8f6-f6d70be734c6', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'rdnLDAPAttribute', 'uid');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('04bafcba-5661-4c45-8524-918e4f945203', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'searchScope', '1');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('1f5db440-daaf-4719-83d1-dba508745096', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'serverPrincipal', 'principal');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('5a6051c4-7999-4193-9764-1acb10a680d4', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'syncRegistrations', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('6d7820ab-94d7-4004-ac8a-1483df91f212', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'useKerberosForPasswordAuthentication', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('64067655-76a1-4fd7-b68c-983aefb053c8', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'userAccountControlsAfterPasswordUpdate', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('adf47f23-45f6-407e-bcc2-41085769d5c1', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'usernameLDAPAttribute', 'uid');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('343b7554-4a8a-4b09-b414-bb4082d4c0a0', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'userObjectClasses', 'inetOrgPerson, organizationalPerson');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('b0d63356-a7ac-4f53-a1ed-0fed8ebe70b8', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'usersDn', 'dn');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('8750ddc8-8d63-46aa-b819-12dfa3ee3c2a', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'useTruststoreSpi', 'ldapsOnly');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('ae5b6803-221f-43f9-a776-f43d5da27218', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'uuidLDAPAttribute', 'nsuniqueid');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('9da1c272-31d2-4bc4-ad9a-1a926a632268', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'vendor', 'rhds');

INSERT INTO dballo13.COMPONENT (ID, REALM_ID, PARENT_ID, NAME, PROVIDER_ID, PROVIDER_TYPE) VALUES ('3e7d0fe2-f575-4779-b6ce-70ac1c61502d', 'Migration2', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'last name', 'user-attribute-ldap-mapper', 'org.keycloak.storage.ldap.mappers.LDAPStorageMapper');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('043c7234-d823-4e39-a288-72bca6257caf', '3e7d0fe2-f575-4779-b6ce-70ac1c61502d', 'always.read.value.from.ldap', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('569f6009-fa64-4305-a04e-a16b42387497', '3e7d0fe2-f575-4779-b6ce-70ac1c61502d', 'is.mandatory.in.ldap', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('5765ca69-467c-4aa4-83a3-9f929f88a06b', '3e7d0fe2-f575-4779-b6ce-70ac1c61502d', 'ldap.attribute', 'sn');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('7f5aed99-e80e-4fe8-a717-1524682f7946', '3e7d0fe2-f575-4779-b6ce-70ac1c61502d', 'read.only', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('000a06ad-ce46-42d3-9c3a-5e23e4ef8767', '3e7d0fe2-f575-4779-b6ce-70ac1c61502d', 'user.model.attribute', 'lastName');

DELETE FROM dballo13.USER_FEDERATION_MAPPER_CONFIG WHERE USER_FEDERATION_MAPPER_ID='3e7d0fe2-f575-4779-b6ce-70ac1c61502d';

DELETE FROM dballo13.USER_FEDERATION_MAPPER WHERE ID='3e7d0fe2-f575-4779-b6ce-70ac1c61502d';

INSERT INTO dballo13.COMPONENT (ID, REALM_ID, PARENT_ID, NAME, PROVIDER_ID, PROVIDER_TYPE) VALUES ('5ff4dcd0-41a0-47bf-9d3a-0aa50377e505', 'Migration2', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'modify date', 'user-attribute-ldap-mapper', 'org.keycloak.storage.ldap.mappers.LDAPStorageMapper');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('09667011-f90c-44a5-96b8-e0638a16c41a', '5ff4dcd0-41a0-47bf-9d3a-0aa50377e505', 'always.read.value.from.ldap', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('14c61ddb-e13e-4b29-a922-c17990ce5f64', '5ff4dcd0-41a0-47bf-9d3a-0aa50377e505', 'is.mandatory.in.ldap', 'false');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('452b2310-9f9d-4645-b80a-a45ca54316b8', '5ff4dcd0-41a0-47bf-9d3a-0aa50377e505', 'ldap.attribute', 'modifyTimestamp');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('32668b5f-36ea-4352-aea0-ce3db9ffd583', '5ff4dcd0-41a0-47bf-9d3a-0aa50377e505', 'read.only', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('b43780f3-19f0-4345-be71-9fe9bca2f947', '5ff4dcd0-41a0-47bf-9d3a-0aa50377e505', 'user.model.attribute', 'modifyTimestamp');

DELETE FROM dballo13.USER_FEDERATION_MAPPER_CONFIG WHERE USER_FEDERATION_MAPPER_ID='5ff4dcd0-41a0-47bf-9d3a-0aa50377e505';

DELETE FROM dballo13.USER_FEDERATION_MAPPER WHERE ID='5ff4dcd0-41a0-47bf-9d3a-0aa50377e505';

INSERT INTO dballo13.COMPONENT (ID, REALM_ID, PARENT_ID, NAME, PROVIDER_ID, PROVIDER_TYPE) VALUES ('97c67167-e285-482e-a63f-682fad6d52b9', 'Migration2', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'email', 'user-attribute-ldap-mapper', 'org.keycloak.storage.ldap.mappers.LDAPStorageMapper');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('b4e4d925-c0e1-486f-a891-2e0d474e596e', '97c67167-e285-482e-a63f-682fad6d52b9', 'always.read.value.from.ldap', 'false');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('6e7c3244-520e-4b8b-8923-d439794686ab', '97c67167-e285-482e-a63f-682fad6d52b9', 'is.mandatory.in.ldap', 'false');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('ff241e92-7e88-49c1-b5d4-6818308aa5d4', '97c67167-e285-482e-a63f-682fad6d52b9', 'ldap.attribute', 'mail');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('cd0403a6-3429-40dd-a023-17f56eb78029', '97c67167-e285-482e-a63f-682fad6d52b9', 'read.only', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('f046ce42-bbcd-4599-a7c7-6b194f707905', '97c67167-e285-482e-a63f-682fad6d52b9', 'user.model.attribute', 'email');

DELETE FROM dballo13.USER_FEDERATION_MAPPER_CONFIG WHERE USER_FEDERATION_MAPPER_ID='97c67167-e285-482e-a63f-682fad6d52b9';

DELETE FROM dballo13.USER_FEDERATION_MAPPER WHERE ID='97c67167-e285-482e-a63f-682fad6d52b9';

INSERT INTO dballo13.COMPONENT (ID, REALM_ID, PARENT_ID, NAME, PROVIDER_ID, PROVIDER_TYPE) VALUES ('d5300551-166c-4eae-907c-fec20a343a79', 'Migration2', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'first name', 'user-attribute-ldap-mapper', 'org.keycloak.storage.ldap.mappers.LDAPStorageMapper');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('e21c6c86-2587-407c-84e0-0d447cbd1c00', 'd5300551-166c-4eae-907c-fec20a343a79', 'always.read.value.from.ldap', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('2f06d4df-ac35-484e-9928-a10cb3d1466c', 'd5300551-166c-4eae-907c-fec20a343a79', 'is.mandatory.in.ldap', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('e17d5a6d-16e8-4424-b530-e04ed37c6370', 'd5300551-166c-4eae-907c-fec20a343a79', 'ldap.attribute', 'cn');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('918fc185-a99f-48dc-bc46-35e8a61ac945', 'd5300551-166c-4eae-907c-fec20a343a79', 'read.only', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('cf1f98f8-f57a-4a03-b910-d139f03af2ae', 'd5300551-166c-4eae-907c-fec20a343a79', 'user.model.attribute', 'firstName');

DELETE FROM dballo13.USER_FEDERATION_MAPPER_CONFIG WHERE USER_FEDERATION_MAPPER_ID='d5300551-166c-4eae-907c-fec20a343a79';

DELETE FROM dballo13.USER_FEDERATION_MAPPER WHERE ID='d5300551-166c-4eae-907c-fec20a343a79';

INSERT INTO dballo13.COMPONENT (ID, REALM_ID, PARENT_ID, NAME, PROVIDER_ID, PROVIDER_TYPE) VALUES ('e725c846-914b-408a-be31-25e49eb7ed00', 'Migration2', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'username', 'user-attribute-ldap-mapper', 'org.keycloak.storage.ldap.mappers.LDAPStorageMapper');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('56c3434c-be77-43c0-997c-d3f9073b15e7', 'e725c846-914b-408a-be31-25e49eb7ed00', 'always.read.value.from.ldap', 'false');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('0f37d963-040e-4500-a794-764498ba41be', 'e725c846-914b-408a-be31-25e49eb7ed00', 'is.mandatory.in.ldap', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('963d35e5-9c1f-4ff0-9643-a6cc4ab9764b', 'e725c846-914b-408a-be31-25e49eb7ed00', 'ldap.attribute', 'uid');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('756868b9-a75c-4492-b817-8bfb615090ec', 'e725c846-914b-408a-be31-25e49eb7ed00', 'read.only', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('74b2a6d4-87b8-42ed-8d3c-acd68f73e8fa', 'e725c846-914b-408a-be31-25e49eb7ed00', 'user.model.attribute', 'username');

DELETE FROM dballo13.USER_FEDERATION_MAPPER_CONFIG WHERE USER_FEDERATION_MAPPER_ID='e725c846-914b-408a-be31-25e49eb7ed00';

DELETE FROM dballo13.USER_FEDERATION_MAPPER WHERE ID='e725c846-914b-408a-be31-25e49eb7ed00';

INSERT INTO dballo13.COMPONENT (ID, REALM_ID, PARENT_ID, NAME, PROVIDER_ID, PROVIDER_TYPE) VALUES ('f769ebf2-6431-408c-98a7-58f7ec947232', 'Migration2', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'creation date', 'user-attribute-ldap-mapper', 'org.keycloak.storage.ldap.mappers.LDAPStorageMapper');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('46532b88-fa28-462a-98f7-3a17be398054', 'f769ebf2-6431-408c-98a7-58f7ec947232', 'always.read.value.from.ldap', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('e954c97b-d5f9-4923-9ed2-40c32b90714e', 'f769ebf2-6431-408c-98a7-58f7ec947232', 'is.mandatory.in.ldap', 'false');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('3d608eb2-3364-45c0-93ba-6e0669477405', 'f769ebf2-6431-408c-98a7-58f7ec947232', 'ldap.attribute', 'createTimestamp');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('a5d5a58d-0b1e-4f29-8a5a-fcce8aa69ea3', 'f769ebf2-6431-408c-98a7-58f7ec947232', 'read.only', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('bd773990-5ea9-42ec-b43b-7cbc31f38553', 'f769ebf2-6431-408c-98a7-58f7ec947232', 'user.model.attribute', 'createTimestamp');

DELETE FROM dballo13.USER_FEDERATION_MAPPER_CONFIG WHERE USER_FEDERATION_MAPPER_ID='f769ebf2-6431-408c-98a7-58f7ec947232';

DELETE FROM dballo13.USER_FEDERATION_MAPPER WHERE ID='f769ebf2-6431-408c-98a7-58f7ec947232';

DELETE FROM dballo13.USER_FEDERATION_CONFIG WHERE USER_FEDERATION_PROVIDER_ID='4dd39136-ae1f-4cb7-b769-ce97e1865aa6';

DELETE FROM dballo13.USER_FEDERATION_PROVIDER WHERE ID='4dd39136-ae1f-4cb7-b769-ce97e1865aa6';

INSERT INTO dballo13.DATABASECHANGELOG (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('2.4.0', 'bburke@redhat.com', 'META-INF/jpa-changelog-2.4.0.xml', NOW(), 32, '7:454d604fbd755d9df3fd9c6329043aa5', 'customChange', '', 'EXECUTED', NULL, NULL, '3.4.1');

--  Changeset META-INF/jpa-changelog-2.5.0.xml::2.5.0::bburke@redhat.com
INSERT INTO dballo13.COMPONENT (ID, REALM_ID, PARENT_ID, NAME, PROVIDER_ID, PROVIDER_TYPE) VALUES ('4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'Migration2', 'Migration2', 'ldap-provider', 'ldap', 'org.keycloak.storage.UserStorageProvider');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('9b6ded15-0b11-4a0a-959e-792490135679', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'priority', '2');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('61f7cd50-1c91-49b6-9120-987d2b2b6e38', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'fullSyncPeriod', '-1');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('c3fe27c4-6bac-425c-b59d-a4d3973e1475', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'changedSyncPeriod', '-1');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('a0ec9622-f0bd-46c5-ad09-f24a770f00cb', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'lastSync', '0');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('f1da8be3-ad8c-47e9-b084-47d6599cb632', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'allowKerberosAuthentication', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('7043e074-b80a-4aba-9499-b9cfc083ec48', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'authType', 'none');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('7e79eec7-8b85-4ced-994d-8426ce4fe819', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'batchSizeForSync', '1001');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('629ab1fc-7360-47ab-9205-5882654a4914', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'connectionPooling', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('ddbe8976-c834-43f2-94c9-7e251200d94d', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'connectionUrl', 'http://localhost');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('fc729555-dab0-47a8-bbc3-08a6fe12a37d', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'debug', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('3e9c62ef-4db7-46cf-87b5-97015c86daf0', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'editMode', 'READ_ONLY');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('b918aa48-2eb5-4a16-bda6-5b0223ea64da', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'kerberosRealm', 'realm');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('76b1580e-38d8-42a1-a8ad-77cc533dd546', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'keyTab', 'keytab');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('190f75aa-0f77-49fd-934a-38812b47c050', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'pagination', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('c55f88ea-e20c-4ffb-ad24-2cd9b7c62110', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'rdnLDAPAttribute', 'uid');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('b3a89ec3-61cb-4a0c-9f4a-d4fcb481aef5', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'searchScope', '1');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('e1c00ff8-3031-49ee-9550-a5a2894bd671', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'serverPrincipal', 'principal');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('e7ae7a72-ee33-4ba1-bde0-543574557d1c', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'syncRegistrations', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('05fe6998-dbe6-4885-bf1a-6793fa18f890', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'useKerberosForPasswordAuthentication', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('4b2189d5-73a1-4515-9b8a-ee4beca76da4', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'userAccountControlsAfterPasswordUpdate', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('7b29cc43-1ab5-4604-9737-a813e9537eea', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'usernameLDAPAttribute', 'uid');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('7c121133-a328-479b-be1d-d55c564fc363', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'userObjectClasses', 'inetOrgPerson, organizationalPerson');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('97f8b17d-31be-4141-b080-46bf6333b94c', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'usersDn', 'dn');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('f418313e-194c-4641-8164-fe335e36044f', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'useTruststoreSpi', 'ldapsOnly');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('fb5bd6a7-361c-4d97-9bf5-2abf4c92ed4d', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'uuidLDAPAttribute', 'nsuniqueid');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('ce00a3a6-876e-4fab-b999-4fe1628acf7c', '4dd39136-ae1f-4cb7-b769-ce97e1865aa6', 'vendor', 'rhds');

DELETE FROM dballo13.USER_FEDERATION_CONFIG WHERE USER_FEDERATION_PROVIDER_ID='4dd39136-ae1f-4cb7-b769-ce97e1865aa6';

DELETE FROM dballo13.USER_FEDERATION_PROVIDER WHERE ID='4dd39136-ae1f-4cb7-b769-ce97e1865aa6';

INSERT INTO dballo13.COMPONENT (ID, REALM_ID, PARENT_ID, NAME, PROVIDER_ID, PROVIDER_TYPE) VALUES ('03b669fa-f86f-42fb-b4a4-88315b3ebeb6', 'Migration2', 'Migration2', 'kerberos-provider', 'kerberos', 'org.keycloak.storage.UserStorageProvider');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('83adc70a-2842-47df-8863-535e8e631c3b', '03b669fa-f86f-42fb-b4a4-88315b3ebeb6', 'priority', '3');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('5653ee64-46d0-4149-9a8b-1db80e4d6dcf', '03b669fa-f86f-42fb-b4a4-88315b3ebeb6', 'fullSyncPeriod', '0');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('d036392b-05b7-40ba-82a1-736f52f16554', '03b669fa-f86f-42fb-b4a4-88315b3ebeb6', 'changedSyncPeriod', '0');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('75877e00-b286-4510-9d3e-3e1ff24c4bbd', '03b669fa-f86f-42fb-b4a4-88315b3ebeb6', 'lastSync', '0');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('bfe8ed54-b605-4eaf-b854-cd3f783f971a', '03b669fa-f86f-42fb-b4a4-88315b3ebeb6', 'allowKerberosAuthentication', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('86d65fbb-8d26-4e41-8c5c-8a762cd84f37', '03b669fa-f86f-42fb-b4a4-88315b3ebeb6', 'allowPasswordAuthentication', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('270c12b1-e21d-4a51-81c0-15505c638b57', '03b669fa-f86f-42fb-b4a4-88315b3ebeb6', 'debug', 'true');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('ef87ebe2-a8fa-46ce-b5df-f73101051afe', '03b669fa-f86f-42fb-b4a4-88315b3ebeb6', 'editMode', 'READ_ONLY');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('54c548dd-215b-4d4d-9498-e45bf484e368', '03b669fa-f86f-42fb-b4a4-88315b3ebeb6', 'kerberosRealm', 'realm');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('295a9622-5dfb-4ae5-815c-e82ca22deb9c', '03b669fa-f86f-42fb-b4a4-88315b3ebeb6', 'keyTab', 'keytab');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('456b89da-7f98-48ef-b256-5f892b849245', '03b669fa-f86f-42fb-b4a4-88315b3ebeb6', 'serverPrincipal', 'principal');

INSERT INTO dballo13.COMPONENT_CONFIG (ID, COMPONENT_ID, NAME, VALUE) VALUES ('a87e90ff-7531-449f-afc3-1756cef4711f', '03b669fa-f86f-42fb-b4a4-88315b3ebeb6', 'updateProfileFirstLogin', 'true');

DELETE FROM dballo13.USER_FEDERATION_CONFIG WHERE USER_FEDERATION_PROVIDER_ID='03b669fa-f86f-42fb-b4a4-88315b3ebeb6';

DELETE FROM dballo13.USER_FEDERATION_PROVIDER WHERE ID='03b669fa-f86f-42fb-b4a4-88315b3ebeb6';

ALTER TABLE dballo13.OFFLINE_USER_SESSION MODIFY USER_ID VARCHAR(255);

INSERT INTO dballo13.DATABASECHANGELOG (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('2.5.0', 'bburke@redhat.com', 'META-INF/jpa-changelog-2.5.0.xml', NOW(), 33, '7:57e98a3077e29caf562f7dbf80c72600', 'customChange, modifyDataType', '', 'EXECUTED', NULL, NULL, '3.4.1');

--  Changeset META-INF/jpa-changelog-2.5.0.xml::2.5.0-unicode-oracle::hmlnarik@redhat.com
INSERT INTO dballo13.DATABASECHANGELOG (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('2.5.0-unicode-oracle', 'hmlnarik@redhat.com', 'META-INF/jpa-changelog-2.5.0.xml', NOW(), 34, '7:e4c7e8f2256210aee71ddc42f538b57a', 'modifyDataType (x13), addColumn, sql, dropColumn, renameColumn, modifyDataType (x2)', '', 'MARK_RAN', NULL, NULL, '3.4.1');

--  Changeset META-INF/jpa-changelog-2.5.0.xml::2.5.0-unicode-other-dbs::hmlnarik@redhat.com
ALTER TABLE dballo13.AUTHENTICATION_FLOW MODIFY DESCRIPTION NVARCHAR(255);

ALTER TABLE dballo13.CLIENT_TEMPLATE MODIFY DESCRIPTION NVARCHAR(255);

ALTER TABLE dballo13.RESOURCE_SERVER_POLICY MODIFY DESCRIPTION NVARCHAR(255);

ALTER TABLE dballo13.CLIENT MODIFY DESCRIPTION NVARCHAR(255);

ALTER TABLE dballo13.CLIENT MODIFY NAME NVARCHAR(255);

ALTER TABLE dballo13.USER_ENTITY DROP KEY UK_RU8TT6T700S9V50BU18WS5HA6;

ALTER TABLE dballo13.USER_ENTITY MODIFY FIRST_NAME NVARCHAR(255);

ALTER TABLE dballo13.USER_ENTITY MODIFY LAST_NAME NVARCHAR(255);

ALTER TABLE dballo13.USER_ENTITY MODIFY USERNAME NVARCHAR(255);

ALTER TABLE dballo13.USER_ENTITY ADD CONSTRAINT UK_RU8TT6T700S9V50BU18WS5HA6 UNIQUE (REALM_ID, USERNAME);

ALTER TABLE dballo13.USERNAME_LOGIN_FAILURE DROP PRIMARY KEY;

ALTER TABLE dballo13.USERNAME_LOGIN_FAILURE MODIFY USERNAME NVARCHAR(255);

ALTER TABLE dballo13.USERNAME_LOGIN_FAILURE MODIFY USERNAME NVARCHAR(255) NOT NULL;

ALTER TABLE dballo13.USERNAME_LOGIN_FAILURE ADD PRIMARY KEY (REALM_ID, USERNAME);

ALTER TABLE dballo13.KEYCLOAK_GROUP MODIFY NAME NVARCHAR(255);

ALTER TABLE dballo13.USER_ATTRIBUTE MODIFY VALUE NVARCHAR(255);

ALTER TABLE dballo13.GROUP_ATTRIBUTE MODIFY VALUE NVARCHAR(255);

ALTER TABLE dballo13.REALM_ATTRIBUTE MODIFY VALUE NVARCHAR(255);

ALTER TABLE dballo13.COMPONENT_CONFIG MODIFY VALUE NVARCHAR(4000);

ALTER TABLE dballo13.KEYCLOAK_ROLE DROP KEY `UK_J3RWUVD56ONTGSUHOGM184WW2-2`;

ALTER TABLE dballo13.KEYCLOAK_ROLE MODIFY NAME NVARCHAR(255);

ALTER TABLE dballo13.KEYCLOAK_ROLE ADD CONSTRAINT `UK_J3RWUVD56ONTGSUHOGM184WW2-2` UNIQUE (NAME, CLIENT_REALM_CONSTRAINT);

ALTER TABLE dballo13.KEYCLOAK_ROLE MODIFY DESCRIPTION NVARCHAR(255);

INSERT INTO dballo13.DATABASECHANGELOG (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('2.5.0-unicode-other-dbs', 'hmlnarik@redhat.com', 'META-INF/jpa-changelog-2.5.0.xml', NOW(), 35, '7:09a43c97e49bc626460480aa1379b522', 'modifyDataType (x5), dropUniqueConstraint, modifyDataType (x3), addUniqueConstraint, dropPrimaryKey, modifyDataType, addNotNullConstraint, addPrimaryKey, modifyDataType (x5), dropUniqueConstraint, modifyDataType, addUniqueConstraint, modifyDataType', '', 'EXECUTED', NULL, NULL, '3.4.1');

--  Changeset META-INF/jpa-changelog-2.5.0.xml::2.5.0-duplicate-email-support::slawomir@dabek.name
ALTER TABLE dballo13.REALM ADD LOGIN_WITH_EMAIL_ALLOWED BIT(1) NOT NULL DEFAULT 1, ADD DUPLICATE_EMAILS_ALLOWED BIT(1) NOT NULL DEFAULT 0;

INSERT INTO dballo13.DATABASECHANGELOG (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('2.5.0-duplicate-email-support', 'slawomir@dabek.name', 'META-INF/jpa-changelog-2.5.0.xml', NOW(), 36, '7:26bfc7c74fefa9126f2ce702fb775553', 'addColumn', '', 'EXECUTED', NULL, NULL, '3.4.1');

--  Changeset META-INF/jpa-changelog-2.5.0.xml::2.5.0-unique-group-names::hmlnarik@redhat.com
ALTER TABLE dballo13.KEYCLOAK_GROUP ADD CONSTRAINT SIBLING_NAMES UNIQUE (REALM_ID, PARENT_GROUP, NAME);

INSERT INTO dballo13.DATABASECHANGELOG (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('2.5.0-unique-group-names', 'hmlnarik@redhat.com', 'META-INF/jpa-changelog-2.5.0.xml', NOW(), 37, '7:a161e2ae671a9020fff61e996a207377', 'addUniqueConstraint', '', 'EXECUTED', NULL, NULL, '3.4.1');

--  Changeset META-INF/jpa-changelog-2.5.1.xml::2.5.1::bburke@redhat.com
ALTER TABLE dballo13.FED_USER_CONSENT ADD CREATED_DATE BIGINT NULL, ADD LAST_UPDATED_DATE BIGINT NULL;

INSERT INTO dballo13.DATABASECHANGELOG (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('2.5.1', 'bburke@redhat.com', 'META-INF/jpa-changelog-2.5.1.xml', NOW(), 38, '7:37fc1781855ac5388c494f1442b3f717', 'addColumn', '', 'EXECUTED', NULL, NULL, '3.4.1');

--  *********************************************************************
--  * Keycloak database creation script - apply this script to empty DB *
--  *********************************************************************

CREATE TABLE dballo13.DATABASECHANGELOG_EXAMPLE_EN (ID VARCHAR(255) NOT NULL, AUTHOR VARCHAR(255) NOT NULL, FILENAME VARCHAR(255) NOT NULL, DATEEXECUTED datetime NOT NULL, ORDEREXECUTED INT NOT NULL, EXECTYPE VARCHAR(10) NOT NULL, MD5SUM VARCHAR(35) NULL, DESCRIPTION VARCHAR(255) NULL, COMMENTS VARCHAR(255) NULL, TAG VARCHAR(255) NULL, LIQUIBASE VARCHAR(20) NULL, CONTEXTS VARCHAR(255) NULL, LABELS VARCHAR(255) NULL);

--  *********************************************************************

--  *********************************************************************
--  Update Database Script
--  *********************************************************************
--  Change Log: META-INF/example-changelog.xml
--  Ran at: 2/1/17 8:01 AM
--  Against: dballo13@host-8-179-105.host.centralci.eng.rdu2.redhat.com@jdbc:mysql://db-02.rhev-ci-vms.eng.rdu2.redhat.com:3306/dballo13?useSSL=false
--  Liquibase version: 3.4.1
--  *********************************************************************

--  Changeset META-INF/example-changelog.xml::example-1.0::erik.mulder@docdatapayments.com
CREATE TABLE dballo13.EXAMPLE_COMPANY (ID VARCHAR(36) NOT NULL, NAME VARCHAR(255) NOT NULL, REALM_ID VARCHAR(36) NOT NULL);

ALTER TABLE dballo13.EXAMPLE_COMPANY ADD PRIMARY KEY (ID);

INSERT INTO dballo13.DATABASECHANGELOG_EXAMPLE_EN (ID, AUTHOR, FILENAME, DATEEXECUTED, ORDEREXECUTED, MD5SUM, DESCRIPTION, COMMENTS, EXECTYPE, CONTEXTS, LABELS, LIQUIBASE) VALUES ('example-1.0', 'erik.mulder@docdatapayments.com', 'META-INF/example-changelog.xml', NOW(), 1, '7:4eb040a6f792db674a0fdd7c79db2cc3', 'createTable, addPrimaryKey', '', 'EXECUTED', NULL, NULL, '3.4.1');

