mirror of
https://github.com/open-metadata/OpenMetadata.git
synced 2026-01-06 12:36:56 +00:00
MINOR: Removed supportsDDL from json schemas (#16171)
This commit is contained in:
parent
3db9dadaa6
commit
0e2736ee74
@ -630,7 +630,9 @@ class BigquerySource(
|
||||
self.connection, table_name, schema_name
|
||||
)
|
||||
schema_definition = (
|
||||
str(schema_definition) if schema_definition is not None else None
|
||||
str(schema_definition.strip())
|
||||
if schema_definition is not None
|
||||
else None
|
||||
)
|
||||
return schema_definition
|
||||
except NotImplementedError:
|
||||
|
||||
@ -161,7 +161,9 @@ class ClickhouseSource(CommonDbSourceService):
|
||||
self.connection, table_name, schema_name
|
||||
)
|
||||
schema_definition = (
|
||||
str(schema_definition) if schema_definition is not None else None
|
||||
str(schema_definition.strip())
|
||||
if schema_definition is not None
|
||||
else None
|
||||
)
|
||||
return schema_definition
|
||||
|
||||
|
||||
@ -366,16 +366,19 @@ class CommonDbSourceService(
|
||||
Get the DDL statement or View Definition for a table
|
||||
"""
|
||||
try:
|
||||
schema_definition = None
|
||||
if table_type in (TableType.View, TableType.MaterializedView):
|
||||
schema_definition = inspector.get_view_definition(
|
||||
table_name, schema_name
|
||||
)
|
||||
else:
|
||||
elif hasattr(inspector, "get_table_ddl"):
|
||||
schema_definition = inspector.get_table_ddl(
|
||||
self.connection, table_name, schema_name
|
||||
)
|
||||
schema_definition = (
|
||||
str(schema_definition) if schema_definition is not None else None
|
||||
str(schema_definition).strip()
|
||||
if schema_definition is not None
|
||||
else None
|
||||
)
|
||||
return schema_definition
|
||||
|
||||
|
||||
@ -108,7 +108,9 @@ class HiveSource(CommonDbSourceService):
|
||||
try:
|
||||
schema_definition = inspector.get_view_definition(table_name, schema_name)
|
||||
schema_definition = (
|
||||
str(schema_definition) if schema_definition is not None else None
|
||||
str(schema_definition).strip()
|
||||
if schema_definition is not None
|
||||
else None
|
||||
)
|
||||
return schema_definition
|
||||
|
||||
|
||||
@ -163,7 +163,9 @@ class OracleSource(StoredProcedureMixin, CommonDbSourceService):
|
||||
schema_definition = definition_fn(table_name, schema_name)
|
||||
|
||||
schema_definition = (
|
||||
str(schema_definition) if schema_definition is not None else None
|
||||
str(schema_definition.strip())
|
||||
if schema_definition is not None
|
||||
else None
|
||||
)
|
||||
return schema_definition
|
||||
|
||||
|
||||
@ -82,7 +82,6 @@ EXPECTED_SERVICE = [
|
||||
connectionArguments=None,
|
||||
supportsMetadataExtraction=True,
|
||||
supportsProfiler=True,
|
||||
supportsDDL=True,
|
||||
supportsDBTExtraction=True,
|
||||
)
|
||||
),
|
||||
|
||||
@ -40,11 +40,6 @@
|
||||
"type": "boolean",
|
||||
"default": true
|
||||
},
|
||||
"supportsDDL": {
|
||||
"description": "Supports DDL",
|
||||
"type": "boolean",
|
||||
"default": true
|
||||
},
|
||||
"supportsDatabase": {
|
||||
"description": "The source service supports the database concept in its hierarchy",
|
||||
"type": "boolean",
|
||||
|
||||
@ -93,10 +93,6 @@
|
||||
"title": "Supports Profiler",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsProfiler"
|
||||
},
|
||||
"supportsDDL": {
|
||||
"title": "Supports DDL",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsDDL"
|
||||
},
|
||||
"supportsDatabase": {
|
||||
"title": "Supports Database",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsDatabase"
|
||||
|
||||
@ -103,10 +103,6 @@
|
||||
"title": "Supports Profiler",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsProfiler"
|
||||
},
|
||||
"supportsDDL": {
|
||||
"title": "Supports DDL",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsDDL"
|
||||
},
|
||||
"supportsQueryComment": {
|
||||
"title": "Supports Query Comment",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsQueryComment"
|
||||
|
||||
@ -89,10 +89,6 @@
|
||||
"title": "Supports Profiler",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsProfiler"
|
||||
},
|
||||
"supportsDDL": {
|
||||
"title": "Supports DDL",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsDDL"
|
||||
},
|
||||
"supportsDatabase": {
|
||||
"title": "Supports Database",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsDatabase"
|
||||
|
||||
@ -111,10 +111,6 @@
|
||||
"title": "Supports Profiler",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsProfiler"
|
||||
},
|
||||
"supportsDDL": {
|
||||
"title": "Supports DDL",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsDDL"
|
||||
},
|
||||
"sampleDataStorageConfig": {
|
||||
"title": "Storage Config for Sample Data",
|
||||
"$ref": "../connectionBasicType.json#/definitions/sampleDataStorageConfig"
|
||||
|
||||
@ -84,10 +84,6 @@
|
||||
"title": "Supports Profiler",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsProfiler"
|
||||
},
|
||||
"supportsDDL": {
|
||||
"title": "Supports DDL",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsDDL"
|
||||
},
|
||||
"supportsDatabase": {
|
||||
"title": "Supports Database",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsDatabase"
|
||||
|
||||
@ -99,10 +99,6 @@
|
||||
"title": "Supports Query Comment",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsQueryComment"
|
||||
},
|
||||
"supportsDDL": {
|
||||
"title": "Supports DDL",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsDDL"
|
||||
},
|
||||
"sampleDataStorageConfig": {
|
||||
"title": "Storage Config for Sample Data",
|
||||
"$ref": "../connectionBasicType.json#/definitions/sampleDataStorageConfig"
|
||||
|
||||
@ -136,10 +136,6 @@
|
||||
"title": "Supports Profiler",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsProfiler"
|
||||
},
|
||||
"supportsDDL": {
|
||||
"title": "Supports DDL",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsDDL"
|
||||
},
|
||||
"supportsQueryComment": {
|
||||
"title": "Supports Query Comment",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsQueryComment"
|
||||
|
||||
@ -110,10 +110,6 @@
|
||||
"title": "Supports Profiler",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsProfiler"
|
||||
},
|
||||
"supportsDDL": {
|
||||
"title": "Supports DDL",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsDDL"
|
||||
},
|
||||
"supportsDatabase": {
|
||||
"title": "Supports Database",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsDatabase"
|
||||
|
||||
@ -94,10 +94,6 @@
|
||||
"title": "Supports Profiler",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsProfiler"
|
||||
},
|
||||
"supportsDDL": {
|
||||
"title": "Supports DDL",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsDDL"
|
||||
},
|
||||
"supportsDatabase": {
|
||||
"title": "Supports Database",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsDatabase"
|
||||
|
||||
@ -117,10 +117,6 @@
|
||||
"title": "Supports Profiler",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsProfiler"
|
||||
},
|
||||
"supportsDDL": {
|
||||
"title": "Supports DDL",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsDDL"
|
||||
},
|
||||
"supportsDatabase": {
|
||||
"title": "Supports Database",
|
||||
"$ref": "../connectionBasicType.json#/definitions/supportsDatabase"
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user