mirror of
https://github.com/open-metadata/OpenMetadata.git
synced 2025-08-18 05:57:17 +00:00
migrate serviceType (#18226)
This commit is contained in:
parent
bff50664b9
commit
c6e12fe703
@ -43,3 +43,18 @@ UPDATE installed_apps SET json = JSON_SET(json, '$.supportsInterrupt', true) whe
|
||||
UPDATE apps_marketplace SET json = JSON_SET(json, '$.supportsInterrupt', true) where name = 'SearchIndexingApplication';
|
||||
|
||||
ALTER TABLE apps_extension_time_series ADD COLUMN appName VARCHAR(256) GENERATED ALWAYS AS (json ->> '$.appName') STORED NOT NULL;
|
||||
|
||||
-- Update serviceType in api_endpoint_entity table
|
||||
UPDATE api_endpoint_entity
|
||||
SET json = JSON_SET(json, '$.serviceType', 'Rest')
|
||||
WHERE JSON_UNQUOTE(JSON_EXTRACT(json, '$.serviceType')) = 'REST';
|
||||
|
||||
-- Update serviceType in api_service_entity table
|
||||
UPDATE api_service_entity
|
||||
SET json = JSON_SET(json, '$.serviceType', 'Rest')
|
||||
WHERE JSON_UNQUOTE(JSON_EXTRACT(json, '$.serviceType')) = 'REST';
|
||||
|
||||
-- Update serviceType in api_collection_entity table
|
||||
UPDATE api_collection_entity
|
||||
SET json = JSON_SET(json, '$.serviceType', 'Rest')
|
||||
WHERE JSON_UNQUOTE(JSON_EXTRACT(json, '$.serviceType')) = 'REST';
|
@ -60,3 +60,18 @@ SET json = jsonb_set(
|
||||
where name = 'SearchIndexingApplication';
|
||||
|
||||
ALTER TABLE apps_extension_time_series ADD COLUMN appName VARCHAR(256) GENERATED ALWAYS AS (json ->> 'appName') STORED NOT NULL;
|
||||
|
||||
-- Update serviceType in api_endpoint_entity table
|
||||
UPDATE api_endpoint_entity
|
||||
SET json = jsonb_set(json, '{serviceType}', '"Rest"')
|
||||
WHERE jsonb_extract_path_text(json, 'serviceType') = 'REST';
|
||||
|
||||
-- Update serviceType in api_service_entity table
|
||||
UPDATE api_service_entity
|
||||
SET json = jsonb_set(json, '{serviceType}', '"Rest"')
|
||||
WHERE jsonb_extract_path_text(json, 'serviceType') = 'REST';
|
||||
|
||||
-- Update serviceType in api_collection_entity table
|
||||
UPDATE api_collection_entity
|
||||
SET json = jsonb_set(json, '{serviceType}', '"Rest"')
|
||||
WHERE jsonb_extract_path_text(json, 'serviceType') = 'REST';
|
Loading…
x
Reference in New Issue
Block a user