2023-05-19 09:43:11 +02:00
|
|
|
-- we are not using the secretsManagerCredentials
|
|
|
|
UPDATE metadata_service_entity
|
|
|
|
SET json = JSON_REMOVE(json, '$.openMetadataServerConnection.secretsManagerCredentials')
|
|
|
|
where name = 'OpenMetadata';
|
2023-06-02 07:19:32 +02:00
|
|
|
|
|
|
|
-- Rename githubCredentials to gitCredentials
|
|
|
|
UPDATE dashboard_service_entity
|
|
|
|
SET json = JSON_INSERT(
|
|
|
|
JSON_REMOVE(json, '$.connection.config.githubCredentials'),
|
|
|
|
'$.connection.config.gitCredentials',
|
|
|
|
JSON_EXTRACT(json, '$.connection.config.githubCredentials')
|
|
|
|
)
|
|
|
|
WHERE serviceType = 'Looker'
|
|
|
|
AND JSON_EXTRACT(json, '$.connection.config.githubCredentials') IS NOT NULL;
|
2023-06-06 11:57:00 +05:30
|
|
|
|
|
|
|
|
|
|
|
-- Rename gcsConfig in BigQuery to gcpConfig
|
|
|
|
UPDATE dbservice_entity
|
|
|
|
SET json = JSON_INSERT(
|
|
|
|
JSON_REMOVE(json, '$.connection.config.credentials.gcsConfig'),
|
|
|
|
'$.connection.config.credentials.gcpConfig',
|
|
|
|
JSON_EXTRACT(json, '$.connection.config.credentials.gcsConfig')
|
|
|
|
) where serviceType in ('BigQuery');
|
|
|
|
|
|
|
|
-- Rename gcsConfig in Datalake to gcpConfig
|
|
|
|
UPDATE dbservice_entity
|
|
|
|
SET json = JSON_INSERT(
|
|
|
|
JSON_REMOVE(json, '$.connection.config.configSource.securityConfig.gcsConfig'),
|
|
|
|
'$.connection.config.configSource.securityConfig.gcpConfig',
|
|
|
|
JSON_EXTRACT(json, '$.connection.config.configSource.securityConfig.gcsConfig')
|
|
|
|
) where serviceType in ('Datalake');
|
|
|
|
|
|
|
|
|
|
|
|
-- Rename gcsConfig in dbt to gcpConfig
|
|
|
|
UPDATE ingestion_pipeline_entity
|
|
|
|
SET json = JSON_INSERT(
|
|
|
|
JSON_REMOVE(json, '$.sourceConfig.config.dbtConfigSource.dbtSecurityConfig.gcsConfig'),
|
|
|
|
'$.sourceConfig.config.dbtConfigdbtSecurityConfig.gcpConfig',
|
|
|
|
JSON_EXTRACT(json, '$.sourceConfig.config.dbtConfigSource.dbtSecurityConfig.gcsConfig')
|
|
|
|
)
|
|
|
|
WHERE json -> '$.sourceConfig.config.type' = 'DBT';
|
2023-06-06 15:22:32 +02:00
|
|
|
|
|
|
|
-- use FQN instead of name for Test Connection Definition
|
|
|
|
ALTER TABLE test_connection_definition
|
|
|
|
ADD fullyQualifiedName VARCHAR(256) GENERATED ALWAYS AS (json ->> '$.fullyQualifiedName') NOT NULL,
|
|
|
|
DROP COLUMN name;
|