From 01208ef4b42701375d1dbf9f2a426d82168f5840 Mon Sep 17 00:00:00 2001 From: harshsoni2024 <64592571+harshsoni2024@users.noreply.github.com> Date: Thu, 7 Nov 2024 21:08:41 +0530 Subject: [PATCH] Connector: add stitch schema (#18452) --- .../data/testConnections/pipeline/stitch.json | 21 ++++++++++ .../pipeline/stitchConnection.json | 42 +++++++++++++++++++ .../entity/services/pipelineService.json | 9 +++- 3 files changed, 71 insertions(+), 1 deletion(-) create mode 100644 openmetadata-service/src/main/resources/json/data/testConnections/pipeline/stitch.json create mode 100644 openmetadata-spec/src/main/resources/json/schema/entity/services/connections/pipeline/stitchConnection.json diff --git a/openmetadata-service/src/main/resources/json/data/testConnections/pipeline/stitch.json b/openmetadata-service/src/main/resources/json/data/testConnections/pipeline/stitch.json new file mode 100644 index 00000000000..6a2657d36ee --- /dev/null +++ b/openmetadata-service/src/main/resources/json/data/testConnections/pipeline/stitch.json @@ -0,0 +1,21 @@ +{ + "name": "Stitch", + "displayName": "Stitch Test Connection", + "description": "This Test Connection validates the access against the server and basic metadata extraction of pipelines.", + "steps": [ + { + "name": "GetSources", + "description": "Get pipeline sources", + "errorMessage": "Failed to get all the sources for pipeline", + "shortCircuit": true, + "mandatory": true + }, + { + "name": "GetDestinations", + "description": "Get pipeline destinations", + "errorMessage": "Failed to get all the destinations for pipeline", + "shortCircuit": true, + "mandatory": true + } + ] +} \ No newline at end of file diff --git a/openmetadata-spec/src/main/resources/json/schema/entity/services/connections/pipeline/stitchConnection.json b/openmetadata-spec/src/main/resources/json/schema/entity/services/connections/pipeline/stitchConnection.json new file mode 100644 index 00000000000..ca0dcd7ffbf --- /dev/null +++ b/openmetadata-spec/src/main/resources/json/schema/entity/services/connections/pipeline/stitchConnection.json @@ -0,0 +1,42 @@ +{ + "$id": "https://open-metadata.org/schema/entity/services/connections/pipeline/stitchConnection.json", + "$schema": "http://json-schema.org/draft-07/schema#", + "title": "StitchConnection", + "description": "Stitch Connection", + "type": "object", + "javaType": "org.openmetadata.schema.services.connections.pipeline.StitchConnection", + "definitions": { + "stitchType": { + "description": "Service type.", + "type": "string", + "enum": ["Stitch"], + "default": "Stitch" + } + }, + "properties": { + "type": { + "title": "Service Type", + "description": "Service Type", + "$ref": "#/definitions/stitchType", + "default": "Stitch" + }, + "hostPort": { + "title": "Host and Port", + "description": "Host and port of the Stitch API host", + "type": "string", + "default": "https://api.stitchdata.com/v4" + }, + "token": { + "title": "JWT Token", + "description": "Token to connect to Stitch api doc", + "type": "string", + "format": "password" + }, + "supportsMetadataExtraction": { + "title": "Supports Metadata Extraction", + "$ref": "../connectionBasicType.json#/definitions/supportsMetadataExtraction" + } + }, + "additionalProperties": false, + "required": ["hostPort", "token"] +} diff --git a/openmetadata-spec/src/main/resources/json/schema/entity/services/pipelineService.json b/openmetadata-spec/src/main/resources/json/schema/entity/services/pipelineService.json index 826eff00d8e..5f2fc56a1f4 100644 --- a/openmetadata-spec/src/main/resources/json/schema/entity/services/pipelineService.json +++ b/openmetadata-spec/src/main/resources/json/schema/entity/services/pipelineService.json @@ -32,7 +32,8 @@ "OpenLineage", "KafkaConnect", "DBTCloud", - "Matillion" + "Matillion", + "Stitch" ], "javaEnums": [ { @@ -82,6 +83,9 @@ }, { "name": "Matillion" + }, + { + "name": "Stitch" } ] }, @@ -143,6 +147,9 @@ }, { "$ref": "./connections/pipeline/matillionConnection.json" + }, + { + "$ref": "./connections/pipeline/stitchConnection.json" } ] }